@Deprecated public class WadlServerResource extends ServerResource
describe()
and
describeMethod(Method, MethodInfo)
methods.describe()
and delegate methods.Constructor and Description |
---|
WadlServerResource()
Deprecated.
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canDescribe(Method method)
Deprecated.
Indicates if the given method exposes its WADL description.
|
protected Representation |
createHtmlRepresentation(ApplicationInfo applicationInfo)
Deprecated.
Creates a new HTML representation for a given
ApplicationInfo
instance describing an application. |
protected Representation |
createWadlRepresentation(ApplicationInfo applicationInfo)
Deprecated.
Creates a new WADL representation for a given
ApplicationInfo
instance describing an application. |
protected Representation |
describe()
Deprecated.
Describes the resource as a standalone WADL document.
|
protected void |
describe(ApplicationInfo applicationInfo)
Deprecated.
Updates the description of the parent application.
|
protected RepresentationInfo |
describe(MethodInfo methodInfo,
java.lang.Class<?> representationClass,
Variant variant)
Deprecated.
Describes a representation class and variant couple as WADL information.
|
protected RepresentationInfo |
describe(MethodInfo methodInfo,
RequestInfo requestInfo,
java.lang.Class<?> representationClass,
Variant variant)
Deprecated.
Describes a representation class and variant couple as WADL information
for the given method and request.
|
protected RepresentationInfo |
describe(MethodInfo methodInfo,
ResponseInfo responseInfo,
java.lang.Class<?> representationClass,
Variant variant)
Deprecated.
Describes a representation class and variant couple as WADL information
for the given method and response.
|
void |
describe(ResourceInfo info)
Deprecated.
Returns a WADL description of the current resource, leveraging the
getResourcePath() method. |
void |
describe(java.lang.String path,
ResourceInfo info)
Deprecated.
Returns a WADL description of the current resource.
|
protected Representation |
describe(Variant variant)
Deprecated.
Describes the resource as a WADL document for the given variant.
|
protected void |
describeDelete(MethodInfo info)
Deprecated.
Describes the DELETE method.
|
protected void |
describeGet(MethodInfo info)
Deprecated.
Describes the GET method.
|
protected MethodInfo |
describeMethod()
Deprecated.
Returns a WADL description of the current method.
|
protected void |
describeMethod(Method method,
MethodInfo info)
Deprecated.
Returns a WADL description of the given method.
|
protected void |
describeOptions(MethodInfo info)
Deprecated.
Describes the OPTIONS method.
|
protected java.util.List<ParameterInfo> |
describeParameters()
Deprecated.
Returns the description of the parameters of this resource.
|
protected void |
describePatch(MethodInfo info)
Deprecated.
Describes the Patch method.
|
protected void |
describePost(MethodInfo info)
Deprecated.
Describes the POST method.
|
protected void |
describePut(MethodInfo info)
Deprecated.
Describes the PUT method.
|
protected void |
doInit()
Deprecated.
|
java.lang.String |
getDescription()
Deprecated.
Returns the description of this documented resource.
|
java.lang.String |
getName()
Deprecated.
Returns the name of this documented resource.
|
protected NamedValue<java.lang.String> |
getParameter(java.lang.String name)
Deprecated.
Returns the first parameter found in the current context (entity, query,
headers, etc) with the given name.
|
protected Series<? extends NamedValue<java.lang.String>> |
getParameters(java.lang.String name)
Deprecated.
Returns a collection of parameters found in the current context (entity,
query, headers, etc) given a parameter name.
|
protected Variant |
getPreferredWadlVariant()
Deprecated.
Returns the preferred WADL variant according to the client preferences
specified in the request.
|
protected java.lang.String |
getResourcePath()
Deprecated.
Returns the resource's relative path.
|
protected Reference |
getResourcesBase()
Deprecated.
Returns the application resources base URI.
|
protected java.util.List<Variant> |
getWadlVariants()
Deprecated.
Returns the available WADL variants.
|
boolean |
isAutoDescribing()
Deprecated.
Indicates if the resource should be automatically described via WADL when
an OPTIONS request is handled.
|
Representation |
options()
Deprecated.
|
void |
setAutoDescribing(boolean autoDescribed)
Deprecated.
Indicates if the resource should be automatically described via WADL when
an OPTIONS request is handled.
|
void |
setDescription(java.lang.String description)
Deprecated.
Sets the description of this documented resource.
|
void |
setName(java.lang.String name)
Deprecated.
Sets the name of this documented resource.
|
abort, commit, delete, delete, describeVariants, doCatch, doConditionalHandle, doError, doHandle, doHandle, doHandle, doNegotiatedHandle, get, get, getAnnotation, getAnnotation, getAnnotations, 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, updateDimensions
doError, 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, toString
public boolean canDescribe(Method method)
describe(String, ResourceInfo)
.method
- The methodprotected Representation createHtmlRepresentation(ApplicationInfo applicationInfo)
ApplicationInfo
instance describing an application.applicationInfo
- The application description.WadlRepresentation
.protected Representation createWadlRepresentation(ApplicationInfo applicationInfo)
ApplicationInfo
instance describing an application.applicationInfo
- The application description.WadlRepresentation
.protected Representation describe()
protected void describe(ApplicationInfo applicationInfo)
applicationInfo
- The parent application.protected RepresentationInfo describe(MethodInfo methodInfo, java.lang.Class<?> representationClass, Variant variant)
methodInfo
- The parent method description.representationClass
- The representation bean class.variant
- The target variant.protected RepresentationInfo describe(MethodInfo methodInfo, RequestInfo requestInfo, java.lang.Class<?> representationClass, Variant variant)
describe(MethodInfo, Class, Variant)
.methodInfo
- The parent method description.requestInfo
- The parent request description.representationClass
- The representation bean class.variant
- The target variant.protected RepresentationInfo describe(MethodInfo methodInfo, ResponseInfo responseInfo, java.lang.Class<?> representationClass, Variant variant)
describe(MethodInfo, Class, Variant)
.methodInfo
- The parent method description.responseInfo
- The parent response description.representationClass
- The representation bean class.variant
- The target variant.public void describe(ResourceInfo info)
getResourcePath()
method.info
- WADL description of the current resource to update.public void describe(java.lang.String path, ResourceInfo info)
path
- Path of the current resource.info
- WADL description of the current resource to update.protected Representation describe(Variant variant)
variant
- The WADL variant.protected void describeDelete(MethodInfo info)
info
- The method description to update.protected void describeGet(MethodInfo info)
ServerResource.getVariants()
method. Thus in the majority of cases, the
method of the super class must be called when overridden.info
- The method description to update.protected MethodInfo describeMethod()
protected void describeMethod(Method method, MethodInfo info)
method
- The method to describe.info
- The method description to update.protected void describeOptions(MethodInfo info)
getWadlVariants()
method.info
- The method description to update.protected java.util.List<ParameterInfo> describeParameters()
protected void describePatch(MethodInfo info)
info
- The method description to update.protected void describePost(MethodInfo info)
info
- The method description to update.protected void describePut(MethodInfo info)
info
- The method description to update.protected void doInit() throws ResourceException
doInit
in class Resource
ResourceException
public java.lang.String getDescription()
getDescription
in class ServerResource
public java.lang.String getName()
getName
in class ServerResource
protected NamedValue<java.lang.String> getParameter(java.lang.String name)
name
- The parameter name.protected Series<? extends NamedValue<java.lang.String>> getParameters(java.lang.String name)
name
- The name of the parameter.protected Variant getPreferredWadlVariant()
protected java.lang.String getResourcePath()
protected Reference getResourcesBase()
protected java.util.List<Variant> getWadlVariants()
public boolean isAutoDescribing()
public Representation options()
options
in class ServerResource
public void setAutoDescribing(boolean autoDescribed)
autoDescribed
- True if the resource should be automatically described via
WADL.public void setDescription(java.lang.String description)
setDescription
in class ServerResource
description
- The description of this documented resource.public void setName(java.lang.String name)
setName
in class ServerResource
name
- The name of this documented resource.Copyright © 2005-2024 Restlet.