Class CertificateIDBC
- java.lang.Object
-
- com.itextpdf.bouncycastle.cert.ocsp.CertificateIDBC
-
- All Implemented Interfaces:
ICertificateID
public class CertificateIDBC extends java.lang.Object implements ICertificateID
Wrapper class forCertificateID.
-
-
Field Summary
Fields Modifier and Type Field Description private org.bouncycastle.cert.ocsp.CertificateIDcertificateIDprivate static AlgorithmIdentifierBCHASH_SHA1private static CertificateIDBCINSTANCE
-
Constructor Summary
Constructors Constructor Description CertificateIDBC(IDigestCalculator digestCalculator, IX509CertificateHolder certificateHolder, java.math.BigInteger bigInteger)Creates new wrapper instance forCertificateID.CertificateIDBC(org.bouncycastle.cert.ocsp.CertificateID certificateID)Creates new wrapper instance forCertificateID.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)Indicates whether some other object is "equal to" this one.org.bouncycastle.cert.ocsp.CertificateIDgetCertificateID()Gets actual org.bouncycastle object being wrapped.IASN1ObjectIdentifiergetHashAlgOID()Calls actualgetHashAlgOIDmethod for the wrapped CertificateID object.IAlgorithmIdentifiergetHashSha1()GetsgetHashSha1constant for the wrapped CertificateID.static CertificateIDBCgetInstance()Gets wrapper instance.java.math.BigIntegergetSerialNumber()Calls actualgetSerialNumbermethod for the wrapped CertificateID object.inthashCode()Returns a hash code value based on the wrapped object.booleanmatchesIssuer(IX509CertificateHolder certificateHolder, IDigestCalculatorProvider provider)Calls actualmatchesIssuermethod for the wrapped CertificateID object.java.lang.StringtoString()DelegatestoStringmethod call to the wrapped object.
-
-
-
Field Detail
-
INSTANCE
private static final CertificateIDBC INSTANCE
-
HASH_SHA1
private static final AlgorithmIdentifierBC HASH_SHA1
-
certificateID
private final org.bouncycastle.cert.ocsp.CertificateID certificateID
-
-
Constructor Detail
-
CertificateIDBC
public CertificateIDBC(org.bouncycastle.cert.ocsp.CertificateID certificateID)
Creates new wrapper instance forCertificateID.- Parameters:
certificateID-CertificateIDto be wrapped
-
CertificateIDBC
public CertificateIDBC(IDigestCalculator digestCalculator, IX509CertificateHolder certificateHolder, java.math.BigInteger bigInteger) throws OCSPExceptionBC
Creates new wrapper instance forCertificateID.- Parameters:
digestCalculator- DigestCalculator wrapper to createCertificateIDcertificateHolder- X509CertificateHolder wrapper to createCertificateIDbigInteger- BigInteger to createCertificateID- Throws:
OCSPExceptionBC- ifOCSPExceptionoccurs duringCertificateIDinstance creation.
-
-
Method Detail
-
getInstance
public static CertificateIDBC getInstance()
Gets wrapper instance.- Returns:
CertificateIDBCinstance.
-
getCertificateID
public org.bouncycastle.cert.ocsp.CertificateID getCertificateID()
Gets actual org.bouncycastle object being wrapped.- Returns:
- wrapped
CertificateID.
-
getHashAlgOID
public IASN1ObjectIdentifier getHashAlgOID()
Calls actualgetHashAlgOIDmethod for the wrapped CertificateID object.- Specified by:
getHashAlgOIDin interfaceICertificateID- Returns:
IASN1ObjectIdentifierhash algorithm OID wrapper.
-
getHashSha1
public IAlgorithmIdentifier getHashSha1()
GetsgetHashSha1constant for the wrapped CertificateID.- Specified by:
getHashSha1in interfaceICertificateID- Returns:
- CertificateID.HASH_SHA1 wrapper.
-
matchesIssuer
public boolean matchesIssuer(IX509CertificateHolder certificateHolder, IDigestCalculatorProvider provider) throws OCSPExceptionBC
Calls actualmatchesIssuermethod for the wrapped CertificateID object.- Specified by:
matchesIssuerin interfaceICertificateID- Parameters:
certificateHolder- X509CertificateHolder wrapperprovider- DigestCalculatorProvider wrapper- Returns:
- boolean value.
- Throws:
OCSPExceptionBC
-
getSerialNumber
public java.math.BigInteger getSerialNumber()
Calls actualgetSerialNumbermethod for the wrapped CertificateID object.- Specified by:
getSerialNumberin interfaceICertificateID- Returns:
- serial number value.
-
equals
public boolean equals(java.lang.Object o)
Indicates whether some other object is "equal to" this one. Compares wrapped objects.- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
Returns a hash code value based on the wrapped object.- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
DelegatestoStringmethod call to the wrapped object.- Overrides:
toStringin classjava.lang.Object
-
-