Package mc.core.system.util.exception
Class UserException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mc.core.system.util.exception.ApplicationException
mc.core.system.util.exception.UserException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
DeleteTiedElementException
used to signal problems or backend activities to user (not necessarily errors). can have several localized and
parametrized message for ui display or notification. Use method
#getLocalizedMessage(String) to retrieve all
messages concatenated.- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionUserException(Object... args) UserException(String message, Object... args) UserException(String message, Throwable cause, Object... args) UserException(String message, UserException.Severity severity, Object... args) UserException(Throwable cause, Object... args) -
Method Summary
Modifier and TypeMethodDescriptionaddMessageLine(String messageKey, Object... args) add a line to message in order to display as one message with several lines using default linebreak String or custom by callinglinebreak(String)getLocalizedMessage(mc.core.system.util.labels.Labels labels, Locale locale) booleansetSeverity(UserException.Severity severity) Methods inherited from class mc.core.system.util.exception.ApplicationException
getArgs, getMessage, log, shouldLogMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
UserException
-
UserException
-
UserException
-
UserException
-
UserException
-
-
Method Details
-
getSeverity
-
setSeverity
-
addMessageLine
add a line to message in order to display as one message with several lines using default linebreak String or custom by callinglinebreak(String)- Parameters:
messageKey- the message key if message is to be converted using a different locale, mandatoryargs- optional
-
linebreak
-
getLocalizedMessage
- Overrides:
getLocalizedMessagein classApplicationException
-
hasSeveralLines
public boolean hasSeveralLines() -
getMessageLines
-