Class ErrorDescriptor
java.lang.Object
org.codehaus.mojo.servicedocgen.descriptor.AbstractDescriptor
org.codehaus.mojo.servicedocgen.descriptor.ErrorDescriptor
- All Implemented Interfaces:
Descriptor
Descriptor for errors/exceptions (any kind of Throwable).- Author:
- hohwille
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringDefault forgetJsonExample().static final StringDefault forgetXmlExample().Fields inherited from interface Descriptor
HTTP_METHOD_DELETE, HTTP_METHOD_GET, HTTP_METHOD_HEAD, HTTP_METHOD_OPTIONS, HTTP_METHOD_PATCH, HTTP_METHOD_POST, HTTP_METHOD_PUT, LOCATION_BODY, LOCATION_COOKIE, LOCATION_FORM_DATA, LOCATION_HEADER, LOCATION_PATH, LOCATION_QUERY, SCHEME_HTTP, SCHEME_HTTPS, SCHEME_WS, SCHEME_WSS, STATUS_CODE_BAD_REQUEST, STATUS_CODE_CONFLICT, STATUS_CODE_FORBIDDEN, STATUS_CODE_INTERNAL_SERVER_ERROR, STATUS_CODE_NO_CONTENT, STATUS_CODE_SUCCESS, STATUS_CODE_UNAUTHORIZED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClass<?> getMatch()voidsetComment(String comment) voidsetErrorClass(Class<?> errorClass) voidsetErrorName(String errorNameRegex) voidsetJsonExample(String jsonExample) voidsetMatch(ErrorDescriptor.Match match) voidsetStatusCode(String statusCode) voidsetXmlExample(String xmlExample) toString()Methods inherited from class AbstractDescriptor
notNull
-
Field Details
-
DEFAULT_JSON_EXAMPLE
-
DEFAULT_XML_EXAMPLE
-
-
Constructor Details
-
ErrorDescriptor
public ErrorDescriptor()
-
-
Method Details
-
getErrorName
- Returns:
- the errorNameRegex
-
setErrorName
- Parameters:
errorNameRegex- is the errorNameRegex to set
-
getJsonExample
- Returns:
- the jsonExample
-
setJsonExample
- Parameters:
jsonExample- is the jsonExample to set
-
getXmlExample
- Returns:
- the xmlExample
-
setXmlExample
- Parameters:
xmlExample- is the xmlExample to set
-
getStatusCode
- Returns:
- the statusCode
-
setStatusCode
- Parameters:
statusCode- is the statusCode to set
-
getComment
- Returns:
- the comment to use if no more specific comment is available (esp. in case of
ErrorDescriptor.Match.always).
-
setComment
- Parameters:
comment- is the comment to set
-
getErrorNamePattern
- Returns:
- the errorNamePattern
-
getMatch
- Returns:
- the match
-
setMatch
- Parameters:
match- is the match to set
-
getErrorClass
- Returns:
- the errorClass
-
setErrorClass
- Parameters:
errorClass- is the errorClass to set
-
toString
-