Package com.oss.asn1

Class HugeOpenType

All Implemented Interfaces:
com.oss.asn1.PDUContainer, Serializable, Cloneable

public class HugeOpenType extends AbstractOpenType
The HugeOpenType class represents the ASN.1 ANY and the open type when the ValueInFile directive has been applied. This class is used to carry any valid huge ASN.1 value as an open type.
Since:
ASN.1/Java 1.4 beta A
See Also:
  • Constructor Details

    • HugeOpenType

      public HugeOpenType()
      The default constructor.
    • HugeOpenType

      public HugeOpenType(AbstractData pdu, Coder coder) throws EncodeNotSupportedException, EncodeFailedException
      Construct an instance of this class with a PDU object reference that represents the un-encoded value of a valid ASN.1 type. The "coder" will be used to encode the 'pdu' into a byte array.
      Parameters:
      pdu - an AbstractData object representing a PDU.
      coder - a Coder object used to encode "pdu".
      Throws:
      EncodeNotSupportedException - when the encoding is disabled.
      EncodeFailedException - when "pdu" cannot be encoded.
    • HugeOpenType

      public HugeOpenType(ByteStorage encodedValue)
      Construct an instance of this class with a ByteStorage object that represents the encoding of a valid ASN.1 type.
      Parameters:
      encodedValue - the ByteStorage of the encoded data to set.
    • HugeOpenType

      public HugeOpenType(ByteStorage encodedValue, TransferSyntax transferSyntax)
      Construct an instance of this class with a ByteStorage object that represents the encoding of a valid ASN.1 type.
      Parameters:
      encodedValue - the ByteStorage of the encoded data to set.
      transferSyntax - identifier of the encoding rules of this encoded data
    • HugeOpenType

      public HugeOpenType(AbstractData decodedValue)
      Construct an instance of this class with an AbstractData object that represents an unencoded value of a valid ASN.1 type.
      Parameters:
      decodedValue - the AbstractData object to set.
  • Method Details

    • getEncodedValue

      public final ByteStorage getEncodedValue()
      Get the encoding of an instance of a valid ASN.1 type. This will be useful for manual decoding. Manual decoding is used by default or when disableAutomaticDecoding() is invoked.
      Returns:
      ByteStorage representing the encoded data.
    • getEncodedValueAsStream

      public final InputStream getEncodedValueAsStream()
      Get the encoding of an instance of a valid ASN.1 type. This will be useful when manual decoding has been used. The stream returned can be passed as the first parameter to the decode method of the Coder. Manual decoding is used by default or when disableAutomaticDecoding() is invoked.
      Specified by:
      getEncodedValueAsStream in class AbstractOpenType
      Returns:
      InputStream representing the encoded data.
    • setEncodedValue

      public final void setEncodedValue(ByteStorage encodedValue)
      Set the encoded data, an encoding of a valid ASN.1 type.
      Parameters:
      encodedValue - the ByteStorage of encoded data to set.
    • setEncodedValue

      public final void setEncodedValue(ByteStorage encodedValue, TransferSyntax transferSyntax)
      Set the encoded data, an encoding of a valid ASN.1 type.
      Parameters:
      encodedValue - the ByteStorage of encoded data to set.
      transferSyntax - identifier of the encoding rules of this encoded data
    • equalTo

      public final boolean equalTo(HugeOpenType that)
      Compare 'this' object to another OpenType object to see if their contents are the same.
      Parameters:
      that - the OpenType object to compare 'this' object to.
      Returns:
      true if contents of both objects are the same.
    • clone

      public Object clone()
      Clone 'this' object.
      Overrides:
      clone in class AbstractData
      Returns:
      deep copy of 'this' object.
    • delete

      public void delete()
      Destroy the instance of the AbstractData. The contract of this method is to facilitate garbage collection by explicit destruction of the data that is no longer needed.
      Overrides:
      delete in class AbstractOpenType
    • setDecodedValue

      public void setDecodedValue(AbstractData decodedValue)
      Set the unencoded data of a valid ASN.1 type.
      Specified by:
      setDecodedValue in interface com.oss.asn1.PDUContainer
      Overrides:
      setDecodedValue in class AbstractOpenType
      Parameters:
      decodedValue - the reference to the AbstractData object to set.