Represents an ASN.1 BIT STRING type. The corresponding Java type is
boolean[]
.
This class has to modes of initialization which play a crucial role in standards compliant DER encoding. One mode initializes instances of this class as a representation of "named bits". The second mode initializes it as a plain bitstring.
An ASN.1 structure with named bits looks e.g., as follows:
Rights ::= BIT STRING { read(0), write(1), execute(2)}
Such bitstrings have a special canonical encoding. The mode (and defaults) are specified in the documentation of the constructors of this class. Basically, in named bits mode, trailing zeroes are truncated from the internal representation of the bitstring.
@author Volker Roth
@author Stefan Endler
@version "$Id: ASN1BitString.java,v 1.3 2007/08/11 18:21:50 sendler Exp $"