Class ODataJPAException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.apache.olingo.odata2.api.exception.ODataException
-
- org.apache.olingo.odata2.jpa.processor.api.exception.ODataJPAException
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ODataJPAModelException,ODataJPARuntimeException
public abstract class ODataJPAException extends ODataException
The exception class is the base of OData JPA exceptions. The class also provides non localized error texts that can be used for raising OData JPA exceptions with non localized error texts.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected static LocaleDEFAULT_LOCALEprotected MessageReferencemessageReferencestatic StringODATA_JPACTX_NULL
-
Constructor Summary
Constructors Modifier Constructor Description protectedODataJPAException(String localizedMessage, Throwable e, MessageReference msgRef)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static MessageReferencecreateMessageReference(Class<? extends ODataJPAException> clazz, String messageReferenceKey)The method creates a Reference to Message ObjectMessageReference.MessageReferencegetMessageReference()-
Methods inherited from class org.apache.olingo.odata2.api.exception.ODataException
getApplicationExceptionCause, getHttpExceptionCause, getMessageExceptionCause, isCausedByApplicationException, isCausedByHttpException, isCausedByMessageException
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Field Detail
-
messageReference
protected MessageReference messageReference
-
ODATA_JPACTX_NULL
public static final String ODATA_JPACTX_NULL
- See Also:
- Constant Field Values
-
DEFAULT_LOCALE
protected static final Locale DEFAULT_LOCALE
-
-
Constructor Detail
-
ODataJPAException
protected ODataJPAException(String localizedMessage, Throwable e, MessageReference msgRef)
-
-
Method Detail
-
createMessageReference
protected static MessageReference createMessageReference(Class<? extends ODataJPAException> clazz, String messageReferenceKey)
The method creates a Reference to Message ObjectMessageReference. The message text key is derived out of parameters clazz.messageReferenceKey.- Parameters:
clazz- is name of the class extendingODataJPAExceptionmessageReferenceKey- is the key of the message- Returns:
- an instance of type
MessageReference
-
getMessageReference
public MessageReference getMessageReference()
-
-