com.jp.comp.calculator
Class CalculatorException
java.lang.Object
java.lang.Throwable
java.lang.Exception
com.jp.comp.calculator.CalculatorException
- All Implemented Interfaces:
- java.io.Serializable
- public class CalculatorException
- extends java.lang.Exception
Calculator exception. Thrown by particular implementation of the calculator operation
- See Also:
CalculatorOperation
,
Serialized Form
Fields inherited from class java.lang.Exception |
|
Constructor Summary |
CalculatorException(java.lang.String anErrMsg)
Constructs the class with specified error message |
CalculatorException(java.lang.String anErrMsg,
java.lang.Object[] aParams)
Constructs the class with specified error message and message parameters to be substituted
by MessageFormat |
Method Summary |
protected static java.lang.String |
formatMessage(java.lang.String aMsg,
java.lang.Object[] aParams)
Formats the message |
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
CalculatorException
public CalculatorException(java.lang.String anErrMsg)
- Constructs the class with specified error message
- Parameters:
anErrMsg
- error message
CalculatorException
public CalculatorException(java.lang.String anErrMsg,
java.lang.Object[] aParams)
- Constructs the class with specified error message and message parameters to be substituted
by
MessageFormat
- Parameters:
anErrMsg
- error messageaParams
- message parameters
formatMessage
protected static java.lang.String formatMessage(java.lang.String aMsg,
java.lang.Object[] aParams)
- Formats the message
- Parameters:
aMsg
- the messageaParams
- message parameters
- Returns:
- formatted message