Package pt.gov.cartaodecidadao
Class PTEID_Certificates
- java.lang.Object
-
- pt.gov.cartaodecidadao.PTEID_Object
-
- pt.gov.cartaodecidadao.PTEID_Certificates
-
public class PTEID_Certificates extends PTEID_Object
Container class for all certificates on the card.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PTEID_Certificate
addCertificate(PTEID_ByteArray cert)
Add a new certificate to the store.void
addToSODCAs(PTEID_ByteArray cert)
long
countAll()
The number of certificates (on the card or not)long
countFromCard()
The number of certificates on the cardvoid
delete()
PTEID_Certificate
getAuthentication()
Return the authentication certificate from the cardPTEID_Certificate
getCA()
Return the ca certificate from the cardPTEID_Certificate
getCert(long ulIndexAll)
Return the certificate with the number ulIndexAll.
ATTENTION ulIndexAll and ulIndexCard are two different index.
Index will change if new certificates are added with addCert().PTEID_Certificate
getCert(PTEID_CertifType type)
Return the certificate by type.PTEID_Certificate
getCertFromCard(long ulIndexCard)
Get the ulIndex certificate from the card.
Throw PTEID_ExParamRange exception if the index is out of range.PTEID_Certificate
getRoot()
Return the root certificate from the cardPTEID_Certificate
getSignature()
Return the signature certificate from the cardvoid
resetSODCAs()
-
-
-
Method Detail
-
delete
public void delete()
- Overrides:
delete
in classPTEID_Object
-
countFromCard
public long countFromCard() throws PTEID_Exception
The number of certificates on the card- Throws:
PTEID_Exception
-
countAll
public long countAll() throws PTEID_Exception
The number of certificates (on the card or not)- Throws:
PTEID_Exception
-
getCertFromCard
public PTEID_Certificate getCertFromCard(long ulIndexCard) throws PTEID_Exception
Get the ulIndex certificate from the card.
Throw PTEID_ExParamRange exception if the index is out of range.- Throws:
PTEID_Exception
-
getCert
public PTEID_Certificate getCert(long ulIndexAll) throws PTEID_Exception
Return the certificate with the number ulIndexAll.
ATTENTION ulIndexAll and ulIndexCard are two different index.
Index will change if new certificates are added with addCert().- Throws:
PTEID_Exception
-
getCert
public PTEID_Certificate getCert(PTEID_CertifType type) throws PTEID_Exception
Return the certificate by type.- Throws:
PTEID_Exception
-
getRoot
public PTEID_Certificate getRoot() throws PTEID_Exception
Return the root certificate from the card- Throws:
PTEID_Exception
-
getCA
public PTEID_Certificate getCA() throws PTEID_Exception
Return the ca certificate from the card- Throws:
PTEID_Exception
-
getSignature
public PTEID_Certificate getSignature() throws PTEID_Exception
Return the signature certificate from the card- Throws:
PTEID_Exception
-
getAuthentication
public PTEID_Certificate getAuthentication() throws PTEID_Exception
Return the authentication certificate from the card- Throws:
PTEID_Exception
-
addCertificate
public PTEID_Certificate addCertificate(PTEID_ByteArray cert) throws PTEID_Exception
Add a new certificate to the store.- Throws:
PTEID_Exception
-
addToSODCAs
public void addToSODCAs(PTEID_ByteArray cert) throws PTEID_Exception
- Throws:
PTEID_Exception
-
resetSODCAs
public void resetSODCAs() throws PTEID_Exception
- Throws:
PTEID_Exception
-
-