Package com.itextpdf.bouncycastle.asn1
Class ASN1InputStreamBC
- java.lang.Object
-
- com.itextpdf.bouncycastle.asn1.ASN1InputStreamBC
-
- All Implemented Interfaces:
IASN1InputStream
,java.io.Closeable
,java.lang.AutoCloseable
public class ASN1InputStreamBC extends java.lang.Object implements IASN1InputStream
Wrapper class forASN1InputStream
.
-
-
Field Summary
Fields Modifier and Type Field Description private org.bouncycastle.asn1.ASN1InputStream
stream
-
Constructor Summary
Constructors Constructor Description ASN1InputStreamBC(byte[] bytes)
Creates new wrapper instance forASN1InputStream
.ASN1InputStreamBC(java.io.InputStream stream)
Creates new wrapper instance forASN1InputStream
.ASN1InputStreamBC(org.bouncycastle.asn1.ASN1InputStream asn1InputStream)
Creates new wrapper instance forASN1InputStream
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Delegatesclose
method call to the wrapped stream.boolean
equals(java.lang.Object o)
Indicates whether some other object is "equal to" this one.org.bouncycastle.asn1.ASN1InputStream
getASN1InputStream()
Gets actual org.bouncycastle object being wrapped.int
hashCode()
Returns a hash code value based on the wrapped object.IASN1Primitive
readObject()
Calls actualreadObject
method for the wrapped ASN1InputStream object.java.lang.String
toString()
DelegatestoString
method call to the wrapped object.
-
-
-
Constructor Detail
-
ASN1InputStreamBC
public ASN1InputStreamBC(org.bouncycastle.asn1.ASN1InputStream asn1InputStream)
Creates new wrapper instance forASN1InputStream
.- Parameters:
asn1InputStream
-ASN1InputStream
to be wrapped
-
ASN1InputStreamBC
public ASN1InputStreamBC(byte[] bytes)
Creates new wrapper instance forASN1InputStream
.- Parameters:
bytes
- byte array to createASN1InputStream
-
ASN1InputStreamBC
public ASN1InputStreamBC(java.io.InputStream stream)
Creates new wrapper instance forASN1InputStream
.- Parameters:
stream
- InputStream to createASN1InputStream
-
-
Method Detail
-
getASN1InputStream
public org.bouncycastle.asn1.ASN1InputStream getASN1InputStream()
Gets actual org.bouncycastle object being wrapped.- Returns:
- wrapped
ASN1InputStream
.
-
readObject
public IASN1Primitive readObject() throws java.io.IOException
Calls actualreadObject
method for the wrapped ASN1InputStream object.- Specified by:
readObject
in interfaceIASN1InputStream
- Returns:
IASN1Primitive
wrapped ASN1Primitive object.- Throws:
java.io.IOException
- if an I/O error occurs.
-
close
public void close() throws java.io.IOException
Delegatesclose
method call to the wrapped stream.- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Specified by:
close
in interfaceIASN1InputStream
- Throws:
java.io.IOException
-
equals
public boolean equals(java.lang.Object o)
Indicates whether some other object is "equal to" this one. Compares wrapped objects.- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
Returns a hash code value based on the wrapped object.- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
DelegatestoString
method call to the wrapped object.- Overrides:
toString
in classjava.lang.Object
-
-