FileDocCategorySizeDatePackage
AttCertValidityPeriod.javaAPI DocAndroid 1.5 API2176Wed May 06 22:41:06 BST 2009org.bouncycastle.asn1.x509

AttCertValidityPeriod

public class AttCertValidityPeriod extends org.bouncycastle.asn1.ASN1Encodable

Fields Summary
org.bouncycastle.asn1.DERGeneralizedTime
notBeforeTime
org.bouncycastle.asn1.DERGeneralizedTime
notAfterTime
Constructors Summary
public AttCertValidityPeriod(org.bouncycastle.asn1.ASN1Sequence seq)

        if (seq.size() != 2)
        {
            throw new IllegalArgumentException("Bad sequence size: "
                    + seq.size());
        }

        notBeforeTime = DERGeneralizedTime.getInstance(seq.getObjectAt(0));
        notAfterTime = DERGeneralizedTime.getInstance(seq.getObjectAt(1));
    
public AttCertValidityPeriod(org.bouncycastle.asn1.DERGeneralizedTime notBeforeTime, org.bouncycastle.asn1.DERGeneralizedTime notAfterTime)

param
notBeforeTime
param
notAfterTime

        this.notBeforeTime = notBeforeTime;
        this.notAfterTime = notAfterTime;
    
Methods Summary
public static org.bouncycastle.asn1.x509.AttCertValidityPeriodgetInstance(java.lang.Object obj)

        if (obj instanceof AttCertValidityPeriod)
        {
            return (AttCertValidityPeriod)obj;
        }
        else if (obj instanceof ASN1Sequence)
        {
            return new AttCertValidityPeriod((ASN1Sequence)obj);
        }
        
        throw new IllegalArgumentException("unknown object in factory");
    
public org.bouncycastle.asn1.DERGeneralizedTimegetNotAfterTime()

        return notAfterTime;
    
public org.bouncycastle.asn1.DERGeneralizedTimegetNotBeforeTime()

        return notBeforeTime;
    
public org.bouncycastle.asn1.DERObjecttoASN1Object()
Produce an object suitable for an ASN1OutputStream.
AttCertValidityPeriod ::= SEQUENCE {
notBeforeTime GeneralizedTime,
notAfterTime GeneralizedTime
}

        ASN1EncodableVector  v = new ASN1EncodableVector();

        v.add(notBeforeTime);
        v.add(notAfterTime);

        return new DERSequence(v);