public class ASN1OctetString extends java.lang.Object implements ASN1TaggedObject
The input may be any valid BER encoding of an ASN.1 octet string. The output is always a DER encoding.
| Constructor and Description |
|---|
ASN1OctetString(byte[] value) |
ASN1OctetString(java.io.InputStream is) |
| Modifier and Type | Method and Description |
|---|---|
ASN1Header |
getHeader() |
byte[] |
getValue() |
void |
input(java.io.InputStream is)
Inputs this object from the specified input stream.
|
static byte[] |
inputValue(java.io.InputStream is) |
int |
length()
Length of this object's encoding.
|
static ASN1Header |
makeHeader(int length) |
void |
output(java.io.OutputStream os)
Outputs this object to the specified output stream.
|
static void |
outputValue(java.io.OutputStream os, byte[] value) |
static void |
outputValue(java.io.OutputStream os, byte[] value, int offset, int len) |
static void |
outputValueWithTag(java.io.OutputStream os, byte[] value, int tag) |
static void |
outputValueWithTag(java.io.OutputStream os, byte[] value, int offset, int len, int tag) |
java.lang.String |
toString() |
public ASN1OctetString(byte[] value)
public ASN1OctetString(java.io.InputStream is)
throws java.io.IOException
java.io.IOExceptionpublic ASN1Header getHeader()
getHeader in interface ASN1TaggedObjectpublic byte[] getValue()
public static ASN1Header makeHeader(int length)
public java.lang.String toString()
toString in class java.lang.Object
public void input(java.io.InputStream is)
throws java.io.IOException
Streamableinput in interface Streamablejava.io.IOException
public static byte[] inputValue(java.io.InputStream is)
throws java.io.IOException
java.io.IOException
public void output(java.io.OutputStream os)
throws java.io.IOException
Streamableoutput in interface Streamablejava.io.IOExceptionpublic int length()
Streamablelength in interface Streamable
public static void outputValue(java.io.OutputStream os,
byte[] value)
throws java.io.IOException
java.io.IOException
public static void outputValue(java.io.OutputStream os,
byte[] value,
int offset,
int len)
throws java.io.IOException
java.io.IOException
public static void outputValueWithTag(java.io.OutputStream os,
byte[] value,
int tag)
throws java.io.IOException
java.io.IOException
public static void outputValueWithTag(java.io.OutputStream os,
byte[] value,
int offset,
int len,
int tag)
throws java.io.IOException
java.io.IOException