Package uicc.suspendresume
Class SuspendException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
javacard.framework.CardRuntimeException
uicc.suspendresume.SuspendException
- All Implemented Interfaces:
Serializable
public class SuspendException
extends javacard.framework.CardRuntimeException
This class extends the
Throwable class and allows the classes of this package
to throw specific exceptions in case of problems.- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final shortThis reason code (= 2) is used to indicate that the compare operation is not recognized because the value is not defined inSuspendConstants.static final shortThis reason code (= 3) is used to indicate that the value in seconds is above the maximum value allowed (221183999 or 0x0D2EFFFF).static final shortThis reason code (= 1) is used to indicate that the time unit format is not recognized because the value is not defined inSuspendConstants. -
Constructor Summary
ConstructorsConstructorDescriptionSuspendException(short reason) Construct aSuspendExceptioninstance with the specified reason. -
Method Summary
Modifier and TypeMethodDescriptionstatic voidthrowIt(short reason) Throws the JCRE instance of theSuspendExceptionclass with the specified reason.Methods inherited from class javacard.framework.CardRuntimeException
getReason, setReasonMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
UNEXPECTED_TIME_UNIT
public static final short UNEXPECTED_TIME_UNITThis reason code (= 1) is used to indicate that the time unit format is not recognized because the value is not defined inSuspendConstants.- See Also:
-
UNEXPECTED_COMPARE
public static final short UNEXPECTED_COMPAREThis reason code (= 2) is used to indicate that the compare operation is not recognized because the value is not defined inSuspendConstants.- See Also:
-
UNEXPECTED_OVERFLOW
public static final short UNEXPECTED_OVERFLOWThis reason code (= 3) is used to indicate that the value in seconds is above the maximum value allowed (221183999 or 0x0D2EFFFF).- See Also:
-
-
Constructor Details
-
SuspendException
public SuspendException(short reason) Construct aSuspendExceptioninstance with the specified reason. To conserve on resources usethrowIt()method to re-use the JCRE instance of this class.- Parameters:
reason- the reason for the exception
-
-
Method Details
-
throwIt
Throws the JCRE instance of theSuspendExceptionclass with the specified reason.- Parameters:
reason- the reason for the exception.- Throws:
SuspendException- always
-