| 
deegree 2.6-pre (2011/11/29 00:10 build-378-unofficial) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.deegree.security.drm.SecurityAccess
public class SecurityAccess
| Field Summary | |
|---|---|
protected  SecurityRegistry | 
registry
 | 
protected  User | 
user
 | 
| Constructor Summary | |
|---|---|
SecurityAccess(User user,
                             SecurityRegistry registry)
 | 
|
| Method Summary | |
|---|---|
protected  void | 
checkForPrivilege(Privilege privilege)
Checks if the associated User has a certain Privilege. | 
protected  void | 
checkForRight(RightType right,
                           SecurableObject object)
Checks if the associated User has a certain Right on the given
 SecurableObject. | 
 Group[] | 
findGroupCycle()
Tries to find a cyle in the groups relations of the Registry. | 
 Group[] | 
getAllGroups()
 | 
 Role[] | 
getAllRoles()
Retrieves all Role s from the Registry, except those that are only used internally
 (these have a namespace starting with the $ symbol); | 
 Role[] | 
getAllRolesForGroup(Group group)
Returns all Role s that the given Group is associated with (directly and via group
 memberships). | 
 Role[] | 
getAllRolesForUser(User user)
Returns all Role s that the given User is associated with (directly and via group
 memberships). | 
 SecuredObject[] | 
getAllSecuredObjects(String type)
 | 
 LinkedList<Service> | 
getAllServices()
 | 
 User[] | 
getAllUsers()
 | 
 String | 
getConstraints(Role role,
                             Service service)
 | 
 Group | 
getGroupById(int id)
 | 
 Group | 
getGroupByName(String name)
 | 
 Privilege | 
getPrivilegeByName(String name)
 | 
 RightType | 
getRightByName(String name)
 | 
 Role | 
getRoleById(int id)
 | 
 Role | 
getRoleByName(String name)
 | 
 Role[] | 
getRolesByNS(String ns)
 | 
 LinkedList<Service> | 
getRolesServices(Role role)
 | 
 SecuredObject | 
getSecuredObjectById(int id)
 | 
 SecuredObject | 
getSecuredObjectByName(String name,
                                             String type)
 | 
 SecuredObject[] | 
getSecuredObjectsByNS(String ns,
                                           String type)
 | 
 Service | 
getServiceByAddress(String address)
 | 
 Service | 
getServiceById(int id)
 | 
 User | 
getUser()
 | 
 User | 
getUserById(int id)
 | 
 User | 
getUserByName(String name)
 | 
 boolean | 
hasServiceRight(Service service,
                               Role role,
                               RightType right)
 | 
| Methods inherited from class java.lang.Object | 
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
protected User user
protected SecurityRegistry registry
| Constructor Detail | 
|---|
SecurityAccess(User user,
               SecurityRegistry registry)
| Method Detail | 
|---|
public User getUser()
public User getUserByName(String name)
                   throws GeneralSecurityException
name - 
GeneralSecurityException
public User getUserById(int id)
                 throws GeneralSecurityException
id - 
GeneralSecurityException
public Group getGroupByName(String name)
                     throws GeneralSecurityException
name - 
GeneralSecurityException
public Group getGroupById(int id)
                   throws GeneralSecurityException
id - 
GeneralSecurityException
public Role getRoleByName(String name)
                   throws GeneralSecurityException
name - 
GeneralSecurityException
public Role[] getRolesByNS(String ns)
                    throws GeneralSecurityException
ns - 
GeneralSecurityException
public Role getRoleById(int id)
                 throws GeneralSecurityException
id - 
GeneralSecurityException
public RightType getRightByName(String name)
                         throws GeneralSecurityException
name - 
GeneralSecurityException
public Privilege getPrivilegeByName(String name)
                             throws GeneralSecurityException
name - 
GeneralSecurityException
public SecuredObject getSecuredObjectById(int id)
                                   throws GeneralSecurityException
id - 
GeneralSecurityException
public SecuredObject getSecuredObjectByName(String name,
                                            String type)
                                     throws GeneralSecurityException
name - type - 
GeneralSecurityException
public SecuredObject[] getSecuredObjectsByNS(String ns,
                                             String type)
                                      throws GeneralSecurityException
ns - type - 
GeneralSecurityException
public User[] getAllUsers()
                   throws GeneralSecurityException
GeneralSecurityException
public Group[] getAllGroups()
                     throws GeneralSecurityException
GeneralSecurityException
public SecuredObject[] getAllSecuredObjects(String type)
                                     throws GeneralSecurityException
type - 
GeneralSecurityException
public Role[] getAllRoles()
                   throws GeneralSecurityException
Role s from the Registry, except those that are only used internally
 (these have a namespace starting with the $ symbol);
GeneralSecurityException
public Role[] getAllRolesForUser(User user)
                          throws GeneralSecurityException
Role s that the given User is associated with (directly and via group
 memberships).
user - 
GeneralSecurityException
public Role[] getAllRolesForGroup(Group group)
                           throws GeneralSecurityException
Role s that the given Group is associated with (directly and via group
 memberships).
group - 
GeneralSecurityException
public Group[] findGroupCycle()
                       throws GeneralSecurityException
Registry.
GeneralSecurityException
protected void checkForPrivilege(Privilege privilege)
                          throws GeneralSecurityException
User has a certain Privilege.
privilege - 
GeneralSecurityException - if holder does not have the privilege
protected void checkForRight(RightType right,
                             SecurableObject object)
                      throws UnauthorizedException,
                             GeneralSecurityException
User has a certain Right on the given
 SecurableObject.
right - object - 
GeneralSecurityException - this is a UnauthorizedException if the holder does not have the right
UnauthorizedException
public Service getServiceByAddress(String address)
                            throws GeneralSecurityException
address - 
GeneralSecurityException
public Service getServiceById(int id)
                       throws GeneralSecurityException
GeneralSecurityException
public LinkedList<Service> getAllServices()
                                   throws GeneralSecurityException
GeneralSecurityException
public LinkedList<Service> getRolesServices(Role role)
                                     throws GeneralSecurityException
role - 
GeneralSecurityException
public boolean hasServiceRight(Service service,
                               Role role,
                               RightType right)
                        throws GeneralSecurityException
GeneralSecurityException
public String getConstraints(Role role,
                             Service service)
                      throws GeneralSecurityException
GeneralSecurityException
  | 
deegree 2.6-pre (2011/11/29 00:10 build-378-unofficial) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
an open source project founded by lat/lon, Bonn, Germany.
                    For more information visit: http://www.deegree.org