org.bouncycastle.asn1
public class DERBitString extends ASN1Object implements DERString
Field Summary | |
---|---|
protected byte[] | data |
protected int | padBits |
Constructor Summary | |
---|---|
protected | DERBitString(byte data, int padBits) |
DERBitString(byte[] data, int padBits) | |
DERBitString(byte[] data) | |
DERBitString(DEREncodable obj) |
Method Summary | |
---|---|
protected boolean | asn1Equals(DERObject o) |
protected static byte[] | getBytes(int bitString)
return the correct number of bytes for a bit string defined in
a 32 bit constant |
byte[] | getBytes() |
static DERBitString | getInstance(Object obj)
return a Bit String from the passed in object
|
static DERBitString | getInstance(ASN1TaggedObject obj, boolean explicit)
return a Bit String from a tagged object.
|
protected static int | getPadBits(int bitString)
return the correct number of pad bits for a bit string defined in
a 32 bit constant |
int | getPadBits() |
String | getString() |
int | hashCode() |
int | intValue() |
String | toString() |
Parameters: data the octets making up the bit string. padBits the number of extra bits at the end of the string.
Throws: IllegalArgumentException if the object cannot be converted.
Parameters: obj the tagged object holding the object we want explicit true if the object is meant to be explicitly tagged false otherwise.
Throws: IllegalArgumentException if the tagged object cannot be converted.
Returns: the value of the bit string as an int (truncating if necessary)