org.silverpeas.password.web
Class PasswordResource

java.lang.Object
  extended by com.silverpeas.web.RESTWebService
      extended by org.silverpeas.password.web.AbstractPasswordResource
          extended by org.silverpeas.password.web.PasswordResource

@Service
@RequestScoped
@Authenticated
public class PasswordResource
extends AbstractPasswordResource

A REST Web resource giving gallery data.

Author:
Yohann Chastagnier

Nested Class Summary
 
Nested classes/interfaces inherited from class com.silverpeas.web.RESTWebService
RESTWebService.WebProcess<RETURN_VALUE>, RESTWebService.WebTreatment<RETURN_VALUE>
 
Field Summary
protected static int nbMatchingCombinedRules
           
protected static ResourceLocator settings
           
 
Fields inherited from class com.silverpeas.web.RESTWebService
RESPONSE_HEADER_ARRAYSIZE, REST_WEB_SERVICES_URI_BASE
 
Constructor Summary
PasswordResource()
           
 
Method Summary
 PasswordCheckEntity checking(PasswordEntity password)
          Gets the JSON representation of a list of errors catched by a password checking.
 PasswordPolicyEntity getPolicy()
          Gets the JSON representation of password policy.
 void validateUserAuthentication(UserPriviledgeValidation validation)
          User authentication is not necessary for this WEB Service.
 
Methods inherited from class org.silverpeas.password.web.AbstractPasswordResource
asWebEntity, asWebEntity, getComponentId, getLanguage
 
Methods inherited from class com.silverpeas.web.RESTWebService
getBundle, getBundleLocation, getGreaterUserRole, getHttpRequest, getHttpServletRequest, getHttpServletResponse, getOrganisationController, getUriInfo, getUserDetail, getUserPreferences, getUserRoles, process, validateUserAuthorization
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

settings

protected static ResourceLocator settings

nbMatchingCombinedRules

protected static int nbMatchingCombinedRules
Constructor Detail

PasswordResource

public PasswordResource()
Method Detail

validateUserAuthentication

public void validateUserAuthentication(UserPriviledgeValidation validation)
                                throws javax.ws.rs.WebApplicationException
User authentication is not necessary for this WEB Service. The authentication processing is used here to identify the user behind the call if possible.

Overrides:
validateUserAuthentication in class RESTWebService
Parameters:
validation - the validation instance to use.
Throws:
javax.ws.rs.WebApplicationException
See Also:
UserPriviledgeValidation

getPolicy

public PasswordPolicyEntity getPolicy()
Gets the JSON representation of password policy. If it doesn't exist, a 404 HTTP code is returned. If a problem occurs when processing the request, a 503 HTTP code is returned.

Returns:
the response to the HTTP GET request with the JSON representation of the asked photo.

checking

public PasswordCheckEntity checking(PasswordEntity password)
Gets the JSON representation of a list of errors catched by a password checking. The returned list contains names of rules which are not verified. If it doesn't exist, a 404 HTTP code is returned. If a problem occurs when processing the request, a 503 HTTP code is returned.

Returns:
the response to the HTTP GET request with the JSON representation of the asked photo.


Copyright © 2016 Silverpeas. All Rights Reserved.