Class ASN1OctetString

java.lang.Object
com.unboundid.asn1.ASN1Element
com.unboundid.asn1.ASN1OctetString
All Implemented Interfaces:
ByteString, Serializable

This class provides an ASN.1 octet string element, whose value is simply comprised of zero or more bytes. Octet string elements are frequently used to represent string values as well.
See Also:
  • Constructor Details

    • ASN1OctetString

      public ASN1OctetString()
      Creates a new ASN.1 octet string element with the default BER type and no value.
    • ASN1OctetString

      public ASN1OctetString(byte type)
      Creates a new ASN.1 octet string element with the specified type and no value.
      Parameters:
      type - The BER type to use for this element.
    • ASN1OctetString

      public ASN1OctetString(@Nullable byte[] value)
      Creates a new ASN.1 octet string element with the default BER type and the provided value.
      Parameters:
      value - The value to use for this element.
    • ASN1OctetString

      public ASN1OctetString(@NotNull byte[] value, int offset, int length)
      Creates a new ASN.1 octet string element with the default BER type and the provided value.
      Parameters:
      value - The byte array containing the value to use for this element It must not be null.
      offset - The offset within the array at which the value begins. It must be greater than or equal to zero and less than or equal to the length of the array.
      length - The length in bytes of the value. It must be greater than or equal to zero, and it must not extend beyond the end of the array.
    • ASN1OctetString

      public ASN1OctetString(byte type, @Nullable byte[] value)
      Creates a new ASN.1 octet string element with the specified type and the provided value.
      Parameters:
      type - The BER type to use for this element.
      value - The value to use for this element.
    • ASN1OctetString

      public ASN1OctetString(byte type, @NotNull byte[] value, int offset, int length)
      Creates a new ASN.1 octet string element with the specified type and the provided value.
      Parameters:
      type - The BER type to use for this element.
      value - The byte array containing the value to use for this element. It must not be null.
      offset - The offset within the array at which the value begins. It must be greater than or equal to zero and less than or equal to the length of the array.
      length - The length in bytes of the value. It must be greater than or equal to zero, and it must not extend beyond the end of the array.
    • ASN1OctetString

      Creates a new ASN.1 octet string element with the default BER type and the provided value.
      Parameters:
      value - The value to use for this element.
    • ASN1OctetString

      public ASN1OctetString(byte type, @Nullable String value)
      Creates a new ASN.1 octet string element with the specified type and the provided value.
      Parameters:
      type - The BER type to use for this element.
      value - The value to use for this element.
  • Method Details