|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.olingo.odata2.api.processor.ODataErrorContext
public class ODataErrorContext
Error context information bean. Usually created and in error situations.
EntityProvider,
ODataErrorCallback| Constructor Summary | |
|---|---|
ODataErrorContext()
create a new context object |
|
| Method Summary | |
|---|---|
String |
getContentType()
Get the content type which should be used to serialize an error response. |
String |
getErrorCode()
Return OData error code that is returned in error response. |
Exception |
getException()
Returns the causing exception. |
HttpStatusCodes |
getHttpStatus()
Get the status code which will be returned in error response. |
String |
getInnerError()
Get a string for a OData inner error to be returned in error response. |
Locale |
getLocale()
Return the locale of the translated message. |
String |
getMessage()
Return a translated error message. |
PathInfo |
getPathInfo()
Get PathInfo object. |
List<String> |
getRequestHeader(String name)
Get the list of values for a request header. |
Map<String,List<String>> |
getRequestHeaders()
Return a map of http headers to be returned in error response. |
URI |
getRequestUri()
Get the request uri to be used in a error response. |
void |
putRequestHeader(String key,
List<String> value)
Put http headers to be returned in error response. |
void |
setContentType(String contentType)
Set content type which should be used to serialize an error response. |
void |
setErrorCode(String errorCode)
Set OData error code that should be returned in error response. |
void |
setException(Exception exception)
Set the causing exception. |
void |
setHttpStatus(HttpStatusCodes status)
Set http status code that should be returned in error response. |
void |
setInnerError(String innerError)
Set a string for a OData inner error to be returned in error response. |
void |
setLocale(Locale locale)
Set the locale for a translated message. |
void |
setMessage(String message)
Set a translated message. |
void |
setPathInfo(PathInfo pathInfo)
Set PathInfo object. |
void |
setRequestUri(URI requestUri)
Set the request uri to be used in a error response. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ODataErrorContext()
| Method Detail |
|---|
public Exception getException()
public void setException(Exception exception)
exception - exception objectpublic String getContentType()
public void setContentType(String contentType)
contentType - a content typepublic HttpStatusCodes getHttpStatus()
public void setHttpStatus(HttpStatusCodes status)
status - http status codepublic String getErrorCode()
public void setErrorCode(String errorCode)
errorCode - an application defined error codepublic String getMessage()
public void setMessage(String message)
message - translated messagepublic Locale getLocale()
public void setLocale(Locale locale)
locale - a locale
public void putRequestHeader(String key,
List<String> value)
key - header namevalue - list of header valuespublic Map<String,List<String>> getRequestHeaders()
public List<String> getRequestHeader(String name)
name - header name
public void setRequestUri(URI requestUri)
requestUri - a uri objectpublic URI getRequestUri()
public String getInnerError()
public void setInnerError(String innerError)
innerError - a inner error messagepublic PathInfo getPathInfo()
PathInfo object.
May be NULL if no path info was created/set till error occurred (but may be over written by
application).
PathInfo or NULL.public void setPathInfo(PathInfo pathInfo)
PathInfo object.
pathInfo - path info
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||