Class: sun.security.acl.AclEntryImpl
- public class AclEntryImpl
- implements AclEntry
This is a class that describes one entry that associates users
or groups with permissions in the ACL.
The entry may be used as a way of granting or denying permissions.
Methods
-
AclEntryImpltop
public AclEntryImpl()Construct a null ACL entry -
AclEntryImpltop
public AclEntryImpl(Principal user)Construct an ACL entry that associates a user with permissions in the ACL. -
addPermissiontop
public boolean addPermission(Permission permission)A principal or a group can be associated with multiple permissions. This method adds a permission to the ACL entry.- Specified by:
- addPermission from AclEntry
-
checkPermissiontop
public boolean checkPermission(Permission permission)Checks if the passed permission is part of the allowed permission set in this entry.- Specified by:
- checkPermission from AclEntry
-
clonetop
public synchronized Object clone()Clones an AclEntry. -
getPrincipaltop
public Principal getPrincipal()Return the Principal associated in this ACL entry. The method returns null if the entry uses a group instead of a principal.- Specified by:
- getPrincipal from AclEntry
-
isNegativetop
public boolean isNegative()Returns true if this is a negative ACL.- Specified by:
- isNegative from AclEntry
-
permissionstop
public Enumeration<Permission> permissions()return an enumeration of the permissions in this ACL entry.- Specified by:
- permissions from AclEntry
-
removePermissiontop
public boolean removePermission(Permission permission)The method disassociates the permission from the Principal or the Group in this ACL entry.- Specified by:
- removePermission from AclEntry
-
setNegativePermissionstop
public void setNegativePermissions()This method sets the ACL to have negative permissions. That is the user or group is denied the permission set specified in the entry.- Specified by:
- setNegativePermissions from AclEntry
-
setPrincipaltop
public boolean setPrincipal(Principal user)Sets the principal in the entity. If a group or a principal had already been set, a false value is returned, otherwise a true value is returned.- Specified by:
- setPrincipal from AclEntry
-
toStringtop
public String toString()Return a string representation of the contents of the ACL entry.
Fields
-
negative
private boolean negative -
permissionSet
private Vector<Permission> permissionSet -
user
private Principal user
