@Requirement(reqId="DOI_DOC_010", reqName="Documentation des interfaces") public abstract class AbstractResource extends org.restlet.ext.wadl.WadlServerResource
| Modifier and Type | Field and Description |
|---|---|
private org.apache.logging.log4j.Logger |
LOG
Logger.
|
| Constructor and Description |
|---|
AbstractResource() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
List<org.restlet.ext.wadl.ParameterInfo> params)
Adds Wadl description of the request to the method.
|
protected void |
addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
List<org.restlet.ext.wadl.ParameterInfo> params,
org.restlet.ext.wadl.RepresentationInfo rep)
Adds Wadl description of the request to the method.
|
protected void |
addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
org.restlet.ext.wadl.ParameterInfo param)
Adds Wadl description of the request to a method.
|
protected void |
addResponseDocToMethod(org.restlet.ext.wadl.MethodInfo info,
org.restlet.ext.wadl.ResponseInfo response)
Adds Wadl description of the response to a method.
|
protected org.restlet.ext.wadl.ParameterInfo |
createQueryParamDoc(String name,
org.restlet.ext.wadl.ParameterStyle style,
String doc,
boolean isRequired,
String datatype)
Creates a query parameter.
|
protected org.restlet.ext.wadl.RepresentationInfo |
createQueryRepresentationDoc(String identifier,
org.restlet.data.MediaType mediaType,
String doc,
String xmlElement)
Creates query representation.
|
protected org.restlet.ext.wadl.ResponseInfo |
createResponseDoc(org.restlet.data.Status status,
String doc)
Creates a textual explanation of the response for a given status.
|
protected org.restlet.ext.wadl.ResponseInfo |
createResponseDoc(org.restlet.data.Status status,
String doc,
org.restlet.ext.wadl.RepresentationInfo representation)
Creates a textual explanation of the response for a given status.
|
protected org.restlet.ext.wadl.ResponseInfo |
createResponseDoc(org.restlet.data.Status status,
String doc,
String refRepresentation)
Creates a textual explanation of the response for a given status.
|
protected void |
doInit()
Init
|
protected org.restlet.ext.wadl.RepresentationInfo |
htmlRepresentation()
projects representation
|
boolean |
isObjectExist(Object obj)
Test if an object is null.
|
boolean |
isObjectNotExist(Object obj)
Test if an object is not null.
|
boolean |
isValueExist(org.restlet.data.Form form,
String parameterName)
Tests if the form is not null and the parameter exists in the form.
|
boolean |
isValueNotExist(org.restlet.data.Form form,
String parameterName)
The opposite of
isValueExist(org.restlet.data.Form, java.lang.String) |
protected org.restlet.ext.wadl.RepresentationInfo |
stringRepresentation()
projects representation
|
canDescribe, createHtmlRepresentation, createWadlRepresentation, describe, describe, describe, describe, describe, describe, describe, describe, describeDelete, describeGet, describeMethod, describeMethod, describeOptions, describeParameters, describePatch, describePost, describePut, getDescription, getName, getParameter, getParameters, getPreferredWadlVariant, getResourcePath, getResourcesBase, getWadlVariants, isAutoDescribing, options, setAutoDescribing, setDescription, setNameabort, commit, delete, delete, describeVariants, doCatch, doConditionalHandle, doError, doHandle, doHandle, doNegotiatedHandle, get, get, getAttribute, getInfo, getInfo, getOnSent, getPreferredVariant, getRole, getVariants, getVariants, handle, hasAnnotations, head, head, isAnnotated, isAutoCommitting, isCommitted, isConditional, isExisting, isInRole, isNegotiated, options, patch, patch, post, post, put, put, redirectPermanent, redirectPermanent, redirectSeeOther, redirectSeeOther, redirectTemporary, redirectTemporary, setAllowedMethods, setAnnotated, setAttribute, setAutoCommitting, setChallengeRequests, setCommitted, setConditional, setCookieSettings, setDimensions, setExisting, setLocationRef, setLocationRef, setNegotiated, setOnSent, setProxyChallengeRequests, setServerInfo, setStatus, setStatus, setStatus, setStatus, updateAllowedMethods, updateDimensionsdoError, doRelease, getAllowedMethods, getApplication, getChallengeRequests, getChallengeResponse, getClientInfo, getConditions, getConnegService, getContext, getConverterService, getCookies, getCookieSettings, getDimensions, getHostRef, getLocationRef, getLogger, getMatrix, getMatrixValue, getMaxForwards, getMetadataService, getMethod, getOriginalRef, getProtocol, getProxyChallengeRequests, getProxyChallengeResponse, getQuery, getQueryValue, getRanges, getReference, getReferrerRef, getRequest, getRequestAttributes, getRequestCacheDirectives, getRequestEntity, getResponse, getResponseAttributes, getResponseCacheDirectives, getResponseEntity, getRootRef, getServerInfo, getStatus, getStatusService, init, isConfidential, isLoggable, release, setApplication, setQueryValue, setRequest, setResponse, toBoolean, toByte, toDouble, toFloat, toInteger, toLong, toObject, toRepresentation, toRepresentation, toRepresentation, toShort, toStringprotected void doInit()
throws org.restlet.resource.ResourceException
doInit in class org.restlet.ext.wadl.WadlServerResourceorg.restlet.resource.ResourceException - When an Exception happenspublic boolean isValueExist(org.restlet.data.Form form,
String parameterName)
form - submitted formparameterName - parameter name in the formpublic boolean isValueNotExist(org.restlet.data.Form form,
String parameterName)
isValueExist(org.restlet.data.Form, java.lang.String)form - submitted formparameterName - parameter namepublic boolean isObjectExist(Object obj)
obj - object to testpublic boolean isObjectNotExist(Object obj)
obj - object to testprotected void addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
org.restlet.ext.wadl.ParameterInfo param)
info - method descriptionparam - Request parametersprotected void addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
List<org.restlet.ext.wadl.ParameterInfo> params)
info - Method descriptionparams - Request parametersprotected void addRequestDocToMethod(org.restlet.ext.wadl.MethodInfo info,
List<org.restlet.ext.wadl.ParameterInfo> params,
org.restlet.ext.wadl.RepresentationInfo rep)
info - Method descriptionparams - Request parametersrep - Representation entity of the requestprotected void addResponseDocToMethod(org.restlet.ext.wadl.MethodInfo info,
org.restlet.ext.wadl.ResponseInfo response)
info - Method descriptionresponse - Response descriptionprotected org.restlet.ext.wadl.ResponseInfo createResponseDoc(org.restlet.data.Status status,
String doc)
status - HTTP Statusdoc - textual explanationprotected org.restlet.ext.wadl.ResponseInfo createResponseDoc(org.restlet.data.Status status,
String doc,
String refRepresentation)
status - HTTP statusdoc - textual explanationrefRepresentation - reference to the representation of the responseprotected org.restlet.ext.wadl.ResponseInfo createResponseDoc(org.restlet.data.Status status,
String doc,
org.restlet.ext.wadl.RepresentationInfo representation)
status - HTTP statusdoc - textual descriptionrepresentation - Representation of the responseprotected org.restlet.ext.wadl.ParameterInfo createQueryParamDoc(String name, org.restlet.ext.wadl.ParameterStyle style, String doc, boolean isRequired, String datatype)
name - query parameter namestyle - Style (header, template, ...)doc - textual descriptionisRequired - optional or requireddatatype - data typeprotected org.restlet.ext.wadl.RepresentationInfo createQueryRepresentationDoc(String identifier, org.restlet.data.MediaType mediaType, String doc, String xmlElement)
identifier - representation identifiermediaType - media typedoc - textual descriptionxmlElement - XML element of the schemaprotected org.restlet.ext.wadl.RepresentationInfo stringRepresentation()
protected org.restlet.ext.wadl.RepresentationInfo htmlRepresentation()
Copyright © 2017–2020 CNES. All rights reserved.