public abstract class Asn1Simple<T> extends AbstractAsn1Type<T>
Asn1Type.EncodingTypebodyLength, outerEncodeable| Constructor and Description |
|---|
Asn1Simple(UniversalTag tagNo)
Default constructor, generally for decoding as a value container
|
Asn1Simple(UniversalTag universalTag,
T value)
Constructor with a value, generally for encoding of the value
|
| Modifier and Type | Method and Description |
|---|---|
static Asn1Simple<?> |
createSimple(int tagNo)
Create a simple ASN1 object given tagNo, using the default constructor
with no value provided
|
static Asn1Simple<?> |
createSimple(UniversalTag tagNo)
Create a simple ASN1 object given tagNo, using the default constructor
with no value provided
|
protected void |
decodeBody(Asn1ParseResult parseResult) |
protected byte[] |
encodeBody() |
protected void |
encodeBody(ByteBuffer buffer) |
protected int |
encodingBodyLength() |
protected byte[] |
getBytes() |
boolean |
isDefinitiveLength()
Tells if it's definitive length or not.
|
static boolean |
isSimple(int tag) |
static boolean |
isSimple(Tag tag) |
static boolean |
isSimple(UniversalTag tagNo) |
protected void |
setBytes(byte[] bytes) |
protected void |
toBytes() |
String |
toString() |
protected void |
toValue() |
getValue, setValuedecode, decode, decode, encode, encode, encodingHeaderLength, encodingLength, getBodyLength, getHeaderLength, isBER, isCER, isDER, isImplicit, isPrimitive, resetBodyLength, taggedDecode, taggedDecode, taggedDecode, taggedEncode, taggedEncode, taggedEncodingLength, useBER, useCER, useDefinitiveLength, useDER, useImplicit, usePrimitiveisAppSpecific, isCollection, isContextSpecific, isEOC, isNull, isSimple, isTagSpecific, isUniversal, simpleInfo, tag, tagFlags, tagNopublic Asn1Simple(UniversalTag tagNo)
tagNo - The tag numberpublic Asn1Simple(UniversalTag universalTag, T value)
universalTag - The tag numbervalue - The valuepublic boolean isDefinitiveLength()
Asn1TypeisDefinitiveLength in interface Asn1TypeisDefinitiveLength in class Asn1Encodeableprotected byte[] getBytes()
protected void setBytes(byte[] bytes)
protected byte[] encodeBody()
protected void encodeBody(ByteBuffer buffer)
encodeBody in class Asn1Encodeableprotected int encodingBodyLength()
encodingBodyLength in class Asn1Encodeableprotected void decodeBody(Asn1ParseResult parseResult) throws IOException
decodeBody in class Asn1EncodeableIOExceptionprotected void toValue()
throws IOException
IOExceptionprotected void toBytes()
public static boolean isSimple(Tag tag)
public static boolean isSimple(int tag)
public static boolean isSimple(UniversalTag tagNo)
public static Asn1Simple<?> createSimple(int tagNo)
tagNo - The tag numberpublic static Asn1Simple<?> createSimple(UniversalTag tagNo)
tagNo - The tag numberpublic String toString()
toString in class AbstractAsn1Type<T>Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.