Package org.apache.kerby.asn1.type
Class Asn1Any
- All Implemented Interfaces:
Asn1Dumpable,Asn1Type
Can be any valid ASN-1 ojbect, limited or not limited.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.kerby.asn1.type.Asn1Type
Asn1Type.EncodingType -
Field Summary
Fields inherited from class org.apache.kerby.asn1.type.Asn1Encodeable
bodyLength, outerEncodeable -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddecode(ByteBuffer content) Decode the content bytes into this type.voiddecode(Asn1ParseResult parseResult) protected voiddecodeBody(Asn1ParseResult parseResult) voiddumpWith(Asn1Dumper dumper, int indents) voidencode(ByteBuffer buffer) Encode the type, by recursively, using the provided buffer.protected intintGet length of encoding bytes by just calculating without real encoding.protected <T extends Asn1Type>
TgetValueAs(Class<T> t) voidsetDecodeInfo(Asn1FieldInfo decodeInfo) voidsetValueType(Class<? extends Asn1Type> valueType) tag()Methods inherited from class org.apache.kerby.asn1.type.AbstractAsn1Type
getValue, setValue, toStringMethods inherited from class org.apache.kerby.asn1.type.Asn1Encodeable
decode, encode, encodeBody, encodingHeaderLength, getBodyLength, getHeaderLength, isBER, isCER, isDefinitiveLength, isDER, isImplicit, isPrimitive, resetBodyLength, taggedDecode, taggedDecode, taggedDecode, taggedEncode, taggedEncode, taggedEncodingLength, useBER, useCER, useDefinitiveLength, useDER, useImplicit, usePrimitiveMethods inherited from class org.apache.kerby.asn1.type.Asn1Object
isAppSpecific, isCollection, isContextSpecific, isEOC, isNull, isSimple, isTagSpecific, isUniversal, simpleInfo, tagFlags, tagNo
-
Constructor Details
-
Asn1Any
public Asn1Any() -
Asn1Any
-
-
Method Details
-
tag
- Specified by:
tagin interfaceAsn1Type- Overrides:
tagin classAsn1Object- Returns:
- The tag
-
setValueType
-
setDecodeInfo
-
getParseResult
-
encode
Description copied from interface:Asn1TypeEncode the type, by recursively, using the provided buffer.- Specified by:
encodein interfaceAsn1Type- Overrides:
encodein classAsn1Encodeable- Parameters:
buffer- The byte buffer- Throws:
IOException
-
encodingLength
public int encodingLength()Description copied from interface:Asn1TypeGet length of encoding bytes by just calculating without real encoding. Generally it's called to prepare for the encoding buffer.- Specified by:
encodingLengthin interfaceAsn1Type- Overrides:
encodingLengthin classAsn1Encodeable- Returns:
- length of encoding bytes
-
encodingBodyLength
protected int encodingBodyLength()- Specified by:
encodingBodyLengthin classAsn1Encodeable
-
decode
Description copied from interface:Asn1TypeDecode the content bytes into this type.- Specified by:
decodein interfaceAsn1Type- Overrides:
decodein classAsn1Encodeable- Parameters:
content- The content bytes- Throws:
IOException- e
-
decode
- Overrides:
decodein classAsn1Encodeable- Throws:
IOException
-
decodeBody
- Specified by:
decodeBodyin classAsn1Encodeable- Throws:
IOException
-
getValueAs
-
dumpWith
- Specified by:
dumpWithin interfaceAsn1Dumpable
-