lumis.util.security.acl
Class AccessControlEntry

Package class diagram package AccessControlEntry
java.lang.Object
  extended by lumis.util.security.acl.AccessControlEntry
All Implemented Interfaces:
Cloneable, ICloneableConfig<AccessControlEntry>

public class AccessControlEntry
extends Object
implements ICloneableConfig<AccessControlEntry>

Value class for an entry of an Access Control List, which represents a principal and its permissions.

Since:
4.0.9

Field Summary
static int COPY_AS_INHERITED
           
static int COPY_AS_NOT_INHERITED
           
 
Constructor Summary
AccessControlEntry(AccessControlEntry parentAccessControlListEntry, int copyType, HashMap<Integer,Integer> permissionsMapping)
           
AccessControlEntry(String principalId, Permissions permissions, boolean inherited)
           
 
Method Summary
 boolean checkPermission(IPermission permission)
           
 AccessControlEntry clone()
           
protected  void deserialize(Node aclEntryNode)
           
 boolean equals(Object obj)
           
 Permissions getPermissions()
           
 String getPrincipalId()
           
 boolean hasDenyPermission(IPermission permission)
          Checks if this ACL Entry has the been denied the given permission.
 int hashCode()
           
 void inherit(AccessControlEntry parentAccessControlListEntry)
           
 void inherit(AccessControlEntry parentAccessControlListEntry, HashMap<Integer,Integer> permissionsMapping)
           
 boolean isInherited()
           
 void removeInheritance()
           
protected  void serialize(AccessControlEntry aclEntry, StringBuilder stringBuilder)
           
 void setImpliedPermissions(int[] permissionImplies)
           
 void setPermissions(Permissions permissions)
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COPY_AS_INHERITED

public static final int COPY_AS_INHERITED
See Also:
Constant Field Values

COPY_AS_NOT_INHERITED

public static final int COPY_AS_NOT_INHERITED
See Also:
Constant Field Values
Constructor Detail

AccessControlEntry

public AccessControlEntry(String principalId,
                          Permissions permissions,
                          boolean inherited)

AccessControlEntry

public AccessControlEntry(AccessControlEntry parentAccessControlListEntry,
                          int copyType,
                          HashMap<Integer,Integer> permissionsMapping)
Method Detail

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

isInherited

public boolean isInherited()

getPermissions

public Permissions getPermissions()

setPermissions

public void setPermissions(Permissions permissions)

getPrincipalId

public String getPrincipalId()

setImpliedPermissions

public void setImpliedPermissions(int[] permissionImplies)

inherit

public void inherit(AccessControlEntry parentAccessControlListEntry)

inherit

public void inherit(AccessControlEntry parentAccessControlListEntry,
                    HashMap<Integer,Integer> permissionsMapping)

removeInheritance

public void removeInheritance()

checkPermission

public boolean checkPermission(IPermission permission)

hasDenyPermission

public boolean hasDenyPermission(IPermission permission)
Checks if this ACL Entry has the been denied the given permission.

Parameters:
permission -
Returns:

serialize

protected void serialize(AccessControlEntry aclEntry,
                         StringBuilder stringBuilder)

deserialize

protected void deserialize(Node aclEntryNode)
                    throws PortalException
Throws:
PortalException

clone

public AccessControlEntry clone()
                         throws CloneNotSupportedException
Specified by:
clone in interface ICloneableConfig<AccessControlEntry>
Overrides:
clone in class Object
Throws:
CloneNotSupportedException


Lumisportal  6.2.0.120405 - Copyright © 2006–2012 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.