ASN1TaggedObject
only, testing
for the expected tag class
of
BERTags.APPLICATION
in relevant objects before using. If using a
stream parser
, handle application-tagged objects using
ASN1TaggedObjectParser
in the usual way, again testing for a
tag class
of BERTags.APPLICATION
.public abstract class ASN1ApplicationSpecific extends ASN1TaggedObject implements ASN1ApplicationSpecificParser
Modifier and Type | Method and Description |
---|---|
int |
getApplicationTag()
Deprecated.
Return the tag number associated with this object,
|
byte[] |
getContents()
Deprecated.
Return the contents of this object as a byte[]
|
ASN1Primitive |
getEnclosedObject()
Deprecated.
Return the enclosed object assuming explicit tagging.
|
static ASN1ApplicationSpecific |
getInstance(java.lang.Object obj)
Deprecated.
Return an ASN1ApplicationSpecific from the passed in object, which may be a byte array, or null.
|
ASN1Primitive |
getObject(int tagNo)
Deprecated.
Return the enclosed object assuming implicit tagging.
|
ASN1Encodable |
getObjectParser(int tag,
boolean isExplicit)
Deprecated.
Return a parser for the actual object tagged.
|
ASN1TaggedObject |
getTaggedObject()
Deprecated.
ASN1ApplicationSpecific uses an internal ASN1TaggedObject for the
implementation, and will soon be deprecated in favour of using
ASN1TaggedObject with a tag class of
BERTags.APPLICATION . |
boolean |
hasApplicationTag(int tagNo)
Deprecated.
|
boolean |
hasContextTag(int tagNo)
Deprecated.
|
boolean |
isConstructed()
Deprecated.
Return true if the object is marked as constructed, false otherwise.
|
ASN1Encodable |
parseBaseUniversal(boolean declaredExplicit,
int baseTagNo)
Deprecated.
|
ASN1Encodable |
parseExplicitBaseObject()
Deprecated.
Needed for open types, until we have better type-guided parsing support.
|
ASN1TaggedObjectParser |
parseExplicitBaseTagged()
Deprecated.
|
ASN1TaggedObjectParser |
parseImplicitBaseTagged(int baseTagClass,
int baseTagNo)
Deprecated.
|
ASN1Encodable |
readObject()
Deprecated.
Read the next object in the parser.
|
getBaseObject, getBaseUniversal, getExplicitBaseObject, getExplicitBaseTagged, getImplicitBaseTagged, getInstance, getLoadedObject, getObject, getTagClass, getTagNo, hashCode, hasTag, isExplicit, toString
encodeTo, encodeTo, equals, equals, equals, fromByteArray, toASN1Primitive
getEncoded, getEncoded, hasEncodedTagValue
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getTagClass, getTagNo, hasTag
toASN1Primitive
getLoadedObject
public static ASN1ApplicationSpecific getInstance(java.lang.Object obj)
obj
- the object to be converted.public int getApplicationTag()
public byte[] getContents()
public ASN1Primitive getEnclosedObject() throws java.io.IOException
java.io.IOException
- if reconstruction fails.public ASN1Primitive getObject(int tagNo) throws java.io.IOException
tagNo
- the type tag that should be applied to the object's contents.java.io.IOException
- if reconstruction fails.public ASN1Encodable getObjectParser(int tag, boolean isExplicit) throws java.io.IOException
ASN1TaggedObjectParser
getObjectParser
in interface ASN1TaggedObjectParser
getObjectParser
in class ASN1TaggedObject
tag
- the primitive tag value for the object tagged originally.isExplicit
- true if the tagging was done explicitly.java.io.IOException
- if a parser cannot be constructed.public ASN1Encodable parseBaseUniversal(boolean declaredExplicit, int baseTagNo) throws java.io.IOException
parseBaseUniversal
in interface ASN1TaggedObjectParser
parseBaseUniversal
in class ASN1TaggedObject
java.io.IOException
public ASN1Encodable parseExplicitBaseObject() throws java.io.IOException
ASN1TaggedObjectParser
ASN1TaggedObjectParser.parseExplicitBaseTagged()
or ASN1TaggedObjectParser.parseBaseUniversal(boolean, int)
where possible. Before using, check for matching tag class
and
number
.parseExplicitBaseObject
in interface ASN1TaggedObjectParser
parseExplicitBaseObject
in class ASN1TaggedObject
java.io.IOException
public ASN1TaggedObjectParser parseExplicitBaseTagged() throws java.io.IOException
parseExplicitBaseTagged
in interface ASN1TaggedObjectParser
parseExplicitBaseTagged
in class ASN1TaggedObject
java.io.IOException
public ASN1TaggedObjectParser parseImplicitBaseTagged(int baseTagClass, int baseTagNo) throws java.io.IOException
parseImplicitBaseTagged
in interface ASN1TaggedObjectParser
parseImplicitBaseTagged
in class ASN1TaggedObject
java.io.IOException
public boolean hasApplicationTag(int tagNo)
public boolean hasContextTag(int tagNo)
hasContextTag
in interface ASN1TaggedObjectParser
hasContextTag
in class ASN1TaggedObject
public ASN1TaggedObject getTaggedObject()
BERTags.APPLICATION
. This method
lets you get the internal ASN1TaggedObject so that client code can begin the
migration.public boolean isConstructed()
public ASN1Encodable readObject() throws java.io.IOException
ASN1ApplicationSpecificParser
readObject
in interface ASN1ApplicationSpecificParser
java.io.IOException
- on a parsing or decoding error.