fr.paris.lutece.plugins.fdw.modules.wizard.rights
Class Rights

java.lang.Object
  extended by fr.paris.lutece.plugins.fdw.modules.wizard.rights.Rights

public class Rights
extends Object

Class Rights


Field Summary
static String PERMISSIONS
           
 
Constructor Summary
Rights()
           
 
Method Summary
 void init(javax.servlet.http.HttpServletRequest request)
          Initialize Rights
 boolean isAuthorized(String resourceType, String permission, String idResource)
          Return true if the user has the given permission
 boolean isAuthorizedJspDirectory(String jsp, String idResource)
          Return true if the user has the right to get into the given jsp (directory) Uses the mapping jsp -> permission
 boolean isAuthorizedJspForm(String jsp, String idResource)
          Return true if the user has the right to get into the given jsp (form) Uses the mapping jsp -> permission
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PERMISSIONS

public static final String PERMISSIONS
See Also:
Constant Field Values
Constructor Detail

Rights

public Rights()
Method Detail

init

public void init(javax.servlet.http.HttpServletRequest request)
Initialize Rights

Parameters:
request - http

isAuthorized

public boolean isAuthorized(String resourceType,
                            String permission,
                            String idResource)
Return true if the user has the given permission

Parameters:
resourceType - type of resource (use case)
permission - key of the permission
idResource - the id of the resource
Returns:
authorized or not (true or false)

isAuthorizedJspForm

public boolean isAuthorizedJspForm(String jsp,
                                   String idResource)
Return true if the user has the right to get into the given jsp (form) Uses the mapping jsp -> permission

Parameters:
jsp - the jsp url
idResource - the id of the resource
Returns:
authorized or not (true or false)

isAuthorizedJspDirectory

public boolean isAuthorizedJspDirectory(String jsp,
                                        String idResource)
Return true if the user has the right to get into the given jsp (directory) Uses the mapping jsp -> permission

Parameters:
jsp - the jsp url
idResource - the id resource
Returns:
authorized or not (true or false)


Copyright © 2013 Mairie de Paris. All Rights Reserved.