| Modifier and Type | Field and Description |
|---|---|
| private static final int | |
| private static final int | |
| private static final int |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static byte | |
| public static byte[] | |
| public static byte[] | |
| public static byte[] | readFixedBytes(InputStream input, int
the number of bytes to read. length)Read a fixed number of bytes from the input stream. |
| public static byte[][] | |
| public static byte[][] | readList(InputStream input, int
the width of the vector's length field, in bytes. listWidth, int the width of each element's length field, in bytes. elemWidth)Read a variable length vector of variable sized elements as described by RFC5246 section 4.3. |
| public static long | readLong(InputStream input, int
the width of the number, in bytes. width)Read a number in big endian format from the input stream. |
| public static int | readNumber(InputStream input, int
the width of the number, in bytes. width)Read a number in big endian format from the input stream. |
| public static byte[] | readVariableBytes(InputStream input, int
the width of the length prefix, in bytes. width)Read a length-prefixed sequence of bytes. |
| public static void | writeFixedBytes(OutputStream output, byte[]
the data to be written. data)Write a fixed number sequence of bytes to the ouput stream. |
| public static void | writeNumber(OutputStream output, long
the value to be written. value, int the width of the encoded number, in bytes width)Write a number to the output stream. |
| public static void | writeVariableBytes(OutputStream output, byte[]
the data to be written. data, int the width of the length prefix, in bytes. width)Write length prefixed sequence of bytes to the ouput stream. |
| DER_LENGTH_LONG_FORM_FLAG | back to summary |
|---|---|
| private static final int DER_LENGTH_LONG_FORM_FLAG | |
| DER_TAG_MASK | back to summary |
|---|---|
| private static final int DER_TAG_MASK | |
| DER_TAG_OCTET_STRING | back to summary |
|---|---|
| private static final int DER_TAG_OCTET_STRING | |
| Serialization | back to summary |
|---|---|
| private Serialization() | |
| readByte | back to summary |
|---|---|
| public static byte readByte(InputStream input) throws SerializationException Read a single byte from the input stream.
| |
| readDEROctetString | back to summary |
|---|---|
| public static byte[] readDEROctetString(byte[] input) throws SerializationException | |
| readDEROctetString | back to summary |
|---|---|
| public static byte[] readDEROctetString(InputStream input) throws SerializationException | |
| readFixedBytes | back to summary |
|---|---|
| public static byte[] readFixedBytes(InputStream input, int length) throws SerializationException Read a fixed number of bytes from the input stream.
| |
| readList | back to summary |
|---|---|
| public static byte[][] readList(byte[] input, int listWidth, int elemWidth) throws SerializationException | |
| readList | back to summary |
|---|---|
| public static byte[][] readList(InputStream input, int listWidth, int elemWidth) throws SerializationException Read a variable length vector of variable sized elements as described by RFC5246 section 4.3. The vector is prefixed by its total length, in bytes and in big endian format, so is each element contained in the vector.
| |
| readLong | back to summary |
|---|---|
| public static long readLong(InputStream input, int width) throws SerializationException Read a number in big endian format from the input stream. This methods supports a width of up to 8 bytes.
| |
| readNumber | back to summary |
|---|---|
| public static int readNumber(InputStream input, int width) throws SerializationException Read a number in big endian format from the input stream. This methods only supports a width of up to 4 bytes.
| |
| readVariableBytes | back to summary |
|---|---|
| public static byte[] readVariableBytes(InputStream input, int width) throws SerializationException Read a length-prefixed sequence of bytes. The length must be encoded in big endian format.
| |
| writeFixedBytes | back to summary |
|---|---|
| public static void writeFixedBytes(OutputStream output, byte[] data) throws SerializationException Write a fixed number sequence of bytes to the ouput stream.
| |
| writeNumber | back to summary |
|---|---|
| public static void writeNumber(OutputStream output, long value, int width) throws SerializationException Write a number to the output stream. The number is encoded in big endian order.
| |
| writeVariableBytes | back to summary |
|---|---|
| public static void writeVariableBytes(OutputStream output, byte[] data, int width) throws SerializationException Write length prefixed sequence of bytes to the ouput stream. The length prefix is encoded in big endian order.
| |