Class ExceptionMessageDefinition
- java.lang.Object
-
- org.odpi.openmetadata.frameworks.auditlog.messagesets.MessageDefinition
-
- org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinition
-
public class ExceptionMessageDefinition extends MessageDefinition
ExceptionMessageDefinition extends MessageDefinition to provide a container that describes a single instance of a message for an exception.
-
-
Constructor Summary
Constructors Constructor Description ExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction)Constructor to save all of the fixed values of a message.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetHttpErrorCode()Return the HTTP code that describes the nature of the exception.StringtoString()JSON-style toString.-
Methods inherited from class org.odpi.openmetadata.frameworks.auditlog.messagesets.MessageDefinition
getMessageId, getMessageParams, getMessageTemplate, getSystemAction, getUserAction, setMessageParameters
-
-
-
-
Constructor Detail
-
ExceptionMessageDefinition
public ExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction)Constructor to save all of the fixed values of a message. This is typically populated from an Enum message set. The constructor passes most values to the super class and just retains the additional value for the exception.- Parameters:
httpErrorCode- the HTTP code that describes the nature of the errormessageId- unique Id for the messagemessageTemplate- text for the messagesystemAction- description of the action taken by the system when the condition happeneduserAction- instructions for resolving the situation, if any
-
-
Method Detail
-
getHttpErrorCode
public int getHttpErrorCode()
Return the HTTP code that describes the nature of the exception.- Returns:
- integer code
-
toString
public String toString()
JSON-style toString.- Overrides:
toStringin classMessageDefinition- Returns:
- list of properties and their values.
-
-