Class ASN1PrimitiveBCFips

java.lang.Object
com.itextpdf.bouncycastlefips.asn1.ASN1EncodableBCFips
com.itextpdf.bouncycastlefips.asn1.ASN1PrimitiveBCFips
All Implemented Interfaces:
IASN1Encodable, IASN1Primitive
Direct Known Subclasses:
ASN1BitStringBCFips, ASN1EnumeratedBCFips, ASN1GeneralizedTimeBCFips, ASN1IntegerBCFips, ASN1ObjectIdentifierBCFips, ASN1OctetStringBCFips, ASN1SequenceBCFips, ASN1SetBCFips, ASN1TaggedObjectBCFips, ASN1UTCTimeBCFips, DERIA5StringBCFips, DERNullBCFips, PKIFailureInfoBCFips

public class ASN1PrimitiveBCFips extends ASN1EncodableBCFips implements IASN1Primitive
Wrapper class for ASN1Primitive.
  • Constructor Details

    • ASN1PrimitiveBCFips

      public ASN1PrimitiveBCFips (org.bouncycastle.asn1.ASN1Primitive primitive)
      Creates new wrapper instance for ASN1Primitive.
      Parameters:
      primitive - ASN1Primitive to be wrapped
    • ASN1PrimitiveBCFips

      public ASN1PrimitiveBCFips (byte[] array) throws IOException
      Creates new wrapper instance for ASN1Primitive.
      Parameters:
      array - byte array to create ASN1Primitive to be wrapped
      Throws:
      IOException - if ASN1Primitive cannot be created from byte array.
  • Method Details

    • getPrimitive

      public org.bouncycastle.asn1.ASN1Primitive getPrimitive()
      Gets actual org.bouncycastle object being wrapped.
      Returns:
      wrapped ASN1Primitive.
    • getEncoded

      public byte[] getEncoded() throws IOException
      Calls actual getEncoded method for the wrapped ASN1Primitive object.
      Specified by:
      getEncoded in interface IASN1Primitive
      Returns:
      the default encoding for the wrapped object.
      Throws:
      IOException - on encoding error.
    • getEncoded

      public byte[] getEncoded (String encoding) throws IOException
      Calls actual getEncoded method for the wrapped ASN1Primitive object.
      Specified by:
      getEncoded in interface IASN1Primitive
      Parameters:
      encoding - encoding value
      Returns:
      the default encoding for the wrapped object.
      Throws:
      IOException - on encoding error.