com.objsys.asn1j.runtime
Class Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

java.lang.Object
  extended by com.objsys.asn1j.runtime.Asn1Type
      extended by com.objsys.asn1j.runtime.Asn1BitString
          extended by com.objsys.asn1j.runtime.Asn1Xer__ABSTRACT_SYNTAX_property_default_Type
All Implemented Interfaces:
Asn1TypeIF, java.io.Serializable, java.lang.Cloneable

public class Asn1Xer__ABSTRACT_SYNTAX_property_default_Type
extends Asn1BitString

See Also:
Serialized Form

Field Summary
static int handles_invalid_encodings
           
 
Fields inherited from class com.objsys.asn1j.runtime.Asn1BitString
ASN1VALUE, BITS, HEX, HEXBIN, mStringFormat, numbits, TAG, trimZeroBits, value
 
Fields inherited from class com.objsys.asn1j.runtime.Asn1Type
BIT_STRING, BMPString, BOOLEAN, DATE, DATE_TIME, DURATION, ENUMERATED, EOC, EXTERNAL, GeneralString, GeneralTime, GraphicString, IA5String, INTEGER, NULL, NumericString, OBJECT_IDENTIFIER, ObjectDescriptor, OCTET_STRING, OID_IRI, OpenType, PrintableString, REAL, RELATIVE_OID_IRI, RelativeOID, SEQUENCE, SET, T61String, TeletexString, TIME, TIME_OF_DAY, UniversalString, UTCTime, UTF8String, VideotexString, VisibleString
 
Constructor Summary
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type()
          This constructor creates an empty bit string that can be used in a decode method call to receive a bit string value.
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(java.util.BitSet bitSet)
          This constructor initializes the bit string value from the given BitSet object.
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(boolean[] bitValues)
          This constructor initializes the bit string value from the given boolean array.
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(byte[] data)
          This constructor initializes the bit string value with the given bytes, using all 8 bits of every byte.
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(int numbits_, byte[] data)
          This constructor initializes the bit string value with the given number of bits and data.
Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(java.lang.String value_)
          This constructor parses the given ASN.1 value text (either a binary or hex data string) and assigns the values to the internal bit string.
 
Method Summary
 void decode(Asn1BerDecodeBuffer buffer, boolean explicit, int implicitLength)
          This method decodes an ASN.1 bit string value using the BER or DER encoding rules.
 void decode(java.lang.Object reader_, java.io.InputStream inputStream)
          This method declaration is the signature of the standard XML Encoding Rules (XER) decode method.
 void decode(java.lang.Object reader_, java.lang.String xmlURI)
          This method declaration is the signature of the standard XML Encoding Rules (XER) decode method.
 int encode(Asn1BerEncodeBuffer buffer, boolean explicit)
          This method encodes an ASN.1 bit string value using the BER or DER encoding rules.
 void encode(Asn1XerEncoder buffer, java.lang.String elemName)
          This method encodes ASN.1 bit string type using the XML encoding rules (XER).
 Asn1XerSaxHandler getSaxHandler()
           
 
Methods inherited from class com.objsys.asn1j.runtime.Asn1BitString
clear, decode, decode, decode, decode, decode, decode, decode, decodeXER, decodeXML, encode, encode, encode, encode, encode, encode, encode, encode, encode, encode, encode, encode, equals, equals, getLength, hashCode, isNamedBitStr, isSet, set, set, toBoolArray, toHexString, toInputStream, toString
 
Methods inherited from class com.objsys.asn1j.runtime.Asn1Type
clone, decode, decode, decode, encode, encode, equals, getTypeName, indent, isOpenType, matchTag, matchTag, pdiag, print, setKey, setOpenType
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

handles_invalid_encodings

public static final int handles_invalid_encodings
See Also:
Constant Field Values
Constructor Detail

Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type()
This constructor creates an empty bit string that can be used in a decode method call to receive a bit string value.


Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(byte[] data)
This constructor initializes the bit string value with the given bytes, using all 8 bits of every byte.

Parameters:
data - Binary bit string contents

Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(int numbits_,
                                                      byte[] data)
This constructor initializes the bit string value with the given number of bits and data.

Parameters:
numbits_ - Number of bits
data - Binary bit string contents

Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(boolean[] bitValues)
This constructor initializes the bit string value from the given boolean array. Each array position corresponds to a bit in the bit string.

Parameters:
bitValues - The boolean array

Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(java.lang.String value_)
                                               throws Asn1ValueParseException
This constructor parses the given ASN.1 value text (either a binary or hex data string) and assigns the values to the internal bit string. Examples of valid value formats are as follows: Binary string: "'11010010111001'B" Hex string: "'0fa56920014abc'H"

Throws:
Asn1ValueParseException

Asn1Xer__ABSTRACT_SYNTAX_property_default_Type

public Asn1Xer__ABSTRACT_SYNTAX_property_default_Type(java.util.BitSet bitSet)
This constructor initializes the bit string value from the given BitSet object. The logical length of the BitSet is used (i.e. position of last set bit).

Parameters:
bitSet - Java BitSet object
Method Detail

decode

public void decode(Asn1BerDecodeBuffer buffer,
                   boolean explicit,
                   int implicitLength)
            throws Asn1Exception,
                   java.io.IOException
Description copied from class: Asn1BitString
This method decodes an ASN.1 bit string value using the BER or DER encoding rules. The UNIVERSAL tag value and length are decoded if explicit tagging is specified.

Specified by:
decode in interface Asn1TypeIF
Overrides:
decode in class Asn1BitString
Parameters:
buffer - Decode message buffer object
explicit - Flag indicating element is explicitly tagged
implicitLength - Length of contents if implicit
Throws:
Asn1Exception
java.io.IOException

encode

public int encode(Asn1BerEncodeBuffer buffer,
                  boolean explicit)
           throws Asn1Exception
Description copied from class: Asn1BitString
This method encodes an ASN.1 bit string value using the BER or DER encoding rules. The UNIVERSAL tag value and length are encoded if explicit tagging is specified.

Specified by:
encode in interface Asn1TypeIF
Overrides:
encode in class Asn1BitString
Parameters:
buffer - Encode message buffer object
explicit - Flag indicating explicit tagging should be done
Returns:
Length of component or negative status value
Throws:
Asn1Exception

decode

public void decode(java.lang.Object reader_,
                   java.lang.String xmlURI)
            throws Asn1Exception,
                   java.io.IOException
Description copied from class: Asn1Type
This method declaration is the signature of the standard XML Encoding Rules (XER) decode method.

Specified by:
decode in interface Asn1TypeIF
Overrides:
decode in class Asn1Type
Parameters:
reader_ - XML reader object
xmlURI - URI of a source
Throws:
Asn1Exception - Thrown, if operation is failed.
java.io.IOException - An IO exception from the parser, possibly from a byte stream or character stream supplied by the application.

decode

public void decode(java.lang.Object reader_,
                   java.io.InputStream inputStream)
            throws Asn1Exception,
                   java.io.IOException
Description copied from class: Asn1Type
This method declaration is the signature of the standard XML Encoding Rules (XER) decode method.

Specified by:
decode in interface Asn1TypeIF
Overrides:
decode in class Asn1Type
Parameters:
reader_ - XML reader object
inputStream - Input byte stream object
Throws:
Asn1Exception - Thrown, if operation is failed.
java.io.IOException - An IO exception from the parser, possibly from a byte stream or character stream supplied by the application.

getSaxHandler

public Asn1XerSaxHandler getSaxHandler()

encode

public void encode(Asn1XerEncoder buffer,
                   java.lang.String elemName)
            throws Asn1Exception,
                   java.io.IOException
Description copied from class: Asn1BitString
This method encodes ASN.1 bit string type using the XML encoding rules (XER).

Specified by:
encode in interface Asn1TypeIF
Overrides:
encode in class Asn1BitString
Parameters:
buffer - Encode message buffer object
elemName - XML element name used to wrap string
Throws:
Asn1Exception - Thrown, if operation is failed.
java.io.IOException - Any exception thrown by the underlying stream.