|
IAIK PKCS#11 Wrapper version 1.2.16 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Throwable
java.lang.Exception
iaik.pkcs.pkcs11.TokenException
iaik.pkcs.pkcs11.wrapper.PKCS11Exception
This is the superclass of all checked exceptions used by this package. An exception of this class indicates that a function call to the underlying PKCS#11 module returned a value not equal to CKR_OK. The application can get the returned value by calling getErrorCode(). A return value not equal to CKR_OK is the only reason for such an exception to be thrown. PKCS#11 defines the meaning of an error-code, which may depend on the context in which the error occurs.
Field Summary | |
protected static String |
ERROR_CODE_PROPERTIES
The name of the properties file that holds the names of the PKCS#11 error- codes. |
protected long |
errorCode_
The code of the error which was the reason for this exception. |
protected static Properties |
errorCodeNames_
The properties object that holds the mapping from error-code to the name of the PKCS#11 error. |
protected static boolean |
errorCodeNamesAvailable_
True, if the mapping of error codes to PKCS#11 error names is available. |
Fields inherited from class iaik.pkcs.pkcs11.TokenException |
encapsulatedException_ |
Constructor Summary | |
PKCS11Exception(long errorCode)
Constructor taking the error code as defined for the CKR_* constants in PKCS#11. |
Method Summary | |
long |
getErrorCode()
Returns the PKCS#11 error code. |
String |
getMessage()
This method gets the corresponding text error message from a property file. |
Methods inherited from class iaik.pkcs.pkcs11.TokenException |
getEncapsulatedException, toString |
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static final String ERROR_CODE_PROPERTIES
protected static Properties errorCodeNames_
protected static boolean errorCodeNamesAvailable_
protected long errorCode_
Constructor Detail |
public PKCS11Exception(long errorCode)
errorCode
- The PKCS#11 error code (return value).Method Detail |
public String getMessage()
public long getErrorCode()
|
IAIK PKCS#11 Wrapper version 1.2.16 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |