public class SecuredResource
extends org.restlet.resource.ServerResource
| Modifier and Type | Field and Description |
|---|---|
protected static String |
ADMIN |
protected org.codehaus.jackson.map.util.ISO8601DateFormat |
isoFormatter |
protected String |
loggedInUser |
protected static String |
USER |
| Constructor and Description |
|---|
SecuredResource() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
authenticate() |
protected boolean |
authenticate(String group) |
String |
createFullResourceUrl(String[] urlFragments,
Object... arguments)
Create a full URL to a rest-resource.
|
protected String |
decode(String string) |
<T extends ActivitiRestApplication> |
getApplication(Class<T> applicationClass) |
String |
getAttribute(String name)
Get a request attribute value, decoded.
|
protected org.restlet.data.Status |
getAuthenticationFailureStatus() |
protected String |
getQueryParameter(String name,
org.restlet.data.Form query) |
protected Boolean |
getQueryParameterAsBoolean(String name,
org.restlet.data.Form query) |
protected Date |
getQueryParameterAsDate(String name,
org.restlet.data.Form query) |
protected Integer |
getQueryParameterAsInt(String name,
org.restlet.data.Form query) |
org.restlet.data.MediaType |
resolveMediaType(String resourceName) |
protected Map<String,Object> |
retrieveVariables(org.codehaus.jackson.JsonNode jsonNode) |
abort, commit, delete, delete, describeVariants, doCatch, doConditionalHandle, doError, doHandle, doHandle, doNegotiatedHandle, get, get, getInfo, getInfo, getOnSent, getPreferredVariant, getVariants, getVariants, handle, hasAnnotations, head, head, isAnnotated, isAutoCommitting, isCommitted, isConditional, isExisting, isInRole, isNegotiated, options, options, 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, doInit, 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, toObject, toRepresentation, toStringprotected static final String USER
protected static final String ADMIN
protected org.codehaus.jackson.map.util.ISO8601DateFormat isoFormatter
protected String loggedInUser
public String createFullResourceUrl(String[] urlFragments, Object... arguments)
urlFragments - fragments of the URL, relative to the base of the rest-application.arguments - arguments to replace the placeholders in the urlFragments, using the MessageFormat
conventions (eg. {0} is replaced by first argument value).public org.restlet.data.MediaType resolveMediaType(String resourceName)
MediaType resolved from the given resource-name. Returns null if the type cannot
be resolved based on the given name.public <T extends ActivitiRestApplication> T getApplication(Class<T> applicationClass)
public String getAttribute(String name)
getAttribute in class org.restlet.resource.ServerResourceprotected String getQueryParameter(String name, org.restlet.data.Form query)
protected Integer getQueryParameterAsInt(String name, org.restlet.data.Form query)
ActivitiIllegalArgumentException - when the query parameter is set but has cannot be converted to an integerprotected Boolean getQueryParameterAsBoolean(String name, org.restlet.data.Form query)
ActivitiIllegalArgumentException - when the query parameter is set but has cannot be converted to a booleanprotected Date getQueryParameterAsDate(String name, org.restlet.data.Form query)
ActivitiIllegalArgumentException - when the query parameter is set but has cannot be converted to a dateprotected boolean authenticate()
protected boolean authenticate(String group)
protected Map<String,Object> retrieveVariables(org.codehaus.jackson.JsonNode jsonNode)
protected org.restlet.data.Status getAuthenticationFailureStatus()
Copyright © 2014 Alfresco. All rights reserved.