Package javacardx.framework.time
Class DateTimeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- javacard.framework.CardRuntimeException
-
- javacardx.framework.time.DateTimeException
-
public class DateTimeException extends CardRuntimeException
Exception used to indicate a problem while calculating a date-time.This exception is used to indicate problems with creating, querying and manipulating date-time objects.
- Since:
- 3.1
-
-
Field Summary
Fields Modifier and Type Field Description static short
INVALID_UNIT
The time unit used has incorrect value or cannot be used to compute an exact durationstatic short
INVALID_VALUE
The time value used is incorrect for the operation
-
Constructor Summary
Constructors Constructor Description DateTimeException(short reason)
Creates aDateTimeException
instance with the specified reason code.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
throwIt(short reason)
Throws the Java Card runtime environment-owned instance ofDateTimeException
with the specified reason.-
Methods inherited from class javacard.framework.CardRuntimeException
getReason, setReason
-
-
-
-
Field Detail
-
INVALID_VALUE
public static final short INVALID_VALUE
The time value used is incorrect for the operation- See Also:
- Constant Field Values
-
INVALID_UNIT
public static final short INVALID_UNIT
The time unit used has incorrect value or cannot be used to compute an exact duration- See Also:
- Constant Field Values
-
-
Method Detail
-
throwIt
public static void throwIt(short reason) throws DateTimeException
Throws the Java Card runtime environment-owned instance ofDateTimeException
with the specified reason.Java Card runtime environment-owned instances of exception classes are temporary Java Card runtime environment Entry Point Objects and can be accessed from any applet context. References to these temporary objects cannot be stored in class variables or instance variables or array components. See Runtime Environment Specification, Java Card Platform, Classic Edition, section 6.2.1 for details.
- Parameters:
reason
- the reason for the exception- Throws:
DateTimeException
- always
-
-