Class ExceptionMessageDefinition
java.lang.Object
org.odpi.openmetadata.frameworks.auditlog.messagesets.MessageDefinition
org.odpi.openmetadata.frameworks.auditlog.messagesets.ExceptionMessageDefinition
ExceptionMessageDefinition extends MessageDefinition to provide a container that describes
a single instance of a message for an exception.
-
Constructor Summary
ConstructorsConstructorDescriptionExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction) Constructor to save all the fixed values of a message.ExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction, String url) Constructor to save all the fixed values of a message, including a link to further reading. -
Method Summary
Modifier and TypeMethodDescriptionintReturn the HTTP code that describes the nature of the exception.toString()JSON-style toString.Methods inherited from class org.odpi.openmetadata.frameworks.auditlog.messagesets.MessageDefinition
getMessageId, getMessageParams, getMessageTemplate, getSystemAction, getURL, getUserAction, setMessageParameters
-
Constructor Details
-
ExceptionMessageDefinition
public ExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction) Constructor to save all 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 identifier 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
-
ExceptionMessageDefinition
public ExceptionMessageDefinition(int httpErrorCode, String messageId, String messageTemplate, String systemAction, String userAction, String url) Constructor to save all the fixed values of a message, including a link to further reading. 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 identifier 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 anyurl- link to a page that describes the component or concept behind this message - null if there is no suitable page.
-
-
Method Details
-
getHttpErrorCode
public int getHttpErrorCode()Return the HTTP code that describes the nature of the exception.- Returns:
- integer code
-
toString
JSON-style toString.- Overrides:
toStringin classMessageDefinition- Returns:
- list of properties and their values.
-