FileDocCategorySizeDatePackage
ReasonFlags.javaAPI DocAndroid 1.5 API3635Wed May 06 22:41:06 BST 2009org.apache.harmony.security.x509

ReasonFlags

public class ReasonFlags extends Object
The class encapsulates the ASN.1 DER encoding/decoding work with the following part of X.509 CRL (as specified in RFC 3280 - Internet X.509 Public Key Infrastructure. Certificate and Certificate Revocation List (CRL) Profile. http://www.ietf.org/rfc/rfc3280.txt):
ReasonFlags ::= BIT STRING {
unused (0),
keyCompromise (1),
cACompromise (2),
affiliationChanged (3),
superseded (4),
cessationOfOperation (5),
certificateHold (6),
privilegeWithdrawn (7),
aACompromise (8)
}

Fields Summary
public static final String[]
REASONS
The names of the reasons.
private boolean[]
flags
public static org.apache.harmony.security.asn1.ASN1BitString
ASN1
ASN.1 Encoder/Decoder.
Constructors Summary
public ReasonFlags(boolean[] flags)
Creates the extension object corresponding to the given flags.

    
                  
       
        this.flags = flags;
    
Methods Summary
public voiddumpValue(java.lang.StringBuffer buffer, java.lang.String prefix)
Places the string representation of extension value into the StringBuffer object.

        buffer.append(prefix);
        buffer.append("ReasonFlags [\n"); //$NON-NLS-1$
        for (int i=0; i<flags.length; i++) {
            if (flags[i]) {
                buffer.append(prefix).append("  ") //$NON-NLS-1$
                    .append(REASONS[i]).append('\n");
            }
        }
        buffer.append(prefix);
        buffer.append("]\n"); //$NON-NLS-1$