Class SchedulerCustomException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- com.redwood.scheduler.api.exception.SchedulerCustomException
-
- All Implemented Interfaces:
ExceptionData,Serializable
public class SchedulerCustomException extends Exception implements ExceptionData
Custom exception, isBestException() returns true so will be chosen by the UI.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SchedulerCustomException(String message)SchedulerCustomException(String message, Throwable cause)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanbestException()Is this exception the best exception for the purposes of the UI? Exceptions implementing this _MUST_ make sure that they display all or more information than their causes.StringgetDefaultMessageFormat()Get the default (US English) message format.StringgetErrorCode()Get the JCS error code of this exception.Object[]getExceptionData()Get the data from the exception for formatting.static StringgetMessageTrace(Throwable cause)static StringgetSQLExceptionInfo(Throwable cause)static StringgetStackTrace(Throwable cause)StringgetTranslation()Get a translation for the exception.booleanisSystemLoggable()Should this exception be logged to the system log, or only to the trace file.booleanskipException()Should this exception be skipped for the purposes of showing an exception dump to the user.-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Method Detail
-
bestException
public boolean bestException()
Description copied from interface:ExceptionDataIs this exception the best exception for the purposes of the UI? Exceptions implementing this _MUST_ make sure that they display all or more information than their causes.- Specified by:
bestExceptionin interfaceExceptionData- Returns:
- true if so, false otherwise.
-
getDefaultMessageFormat
public String getDefaultMessageFormat()
Description copied from interface:ExceptionDataGet the default (US English) message format.- Specified by:
getDefaultMessageFormatin interfaceExceptionData- Returns:
- the message format
-
getErrorCode
public final String getErrorCode()
Description copied from interface:ExceptionDataGet the JCS error code of this exception.- Specified by:
getErrorCodein interfaceExceptionData- Returns:
- the JCS error code, without the leading "JCS-"
-
getExceptionData
public Object[] getExceptionData()
Description copied from interface:ExceptionDataGet the data from the exception for formatting.- Specified by:
getExceptionDatain interfaceExceptionData- Returns:
- the exception data.
-
getTranslation
public String getTranslation()
Description copied from interface:ExceptionDataGet a translation for the exception.- Specified by:
getTranslationin interfaceExceptionData- Returns:
- a translatable description of this exception.
-
isSystemLoggable
public boolean isSystemLoggable()
Description copied from interface:ExceptionDataShould this exception be logged to the system log, or only to the trace file.- Specified by:
isSystemLoggablein interfaceExceptionData- Returns:
- whether this should be logged to the system log, or only to the trace file
-
skipException
public boolean skipException()
Description copied from interface:ExceptionDataShould this exception be skipped for the purposes of showing an exception dump to the user.- Specified by:
skipExceptionin interfaceExceptionData- Returns:
- true if so, false otherwise.
-
-