org.starhope.appius.sys.admin
Class Security
java.lang.Object
org.starhope.appius.sys.admin.Security
public class Security
- extends Object
WRITEME: Document this type.
- Author:
- brpocock@star-hope.org
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
capabilities
static CapabilityRecords capabilities
- WRITEME
Security
public Security()
grantCapability
public static void grantCapability(AbstractUser grantor,
AbstractUser recipient,
SecurityCapability cap)
throws PrivilegeRequiredException
- Parameters:
grantor
- WRITEMErecipient
- WRITEMEcap
- WRITEME
- Throws:
PrivilegeRequiredException
- WRITEME
hasCapability
public static boolean hasCapability(AbstractUser who,
Integer capabilityID)
- This is a convenience method, principally for using the constants
in
SecurityCapability
like
SecurityCapability.CAP_SYSOP_COMMANDS
and the like.
- Parameters:
who
- the user being queriedcapabilityID
- The numeric ID of the security capability in
question
- Returns:
- true, if the user has the capability
hasCapability
public static boolean hasCapability(AbstractUser who,
SecurityCapability cap)
- Determine whether the user possesses a particular security
capability.
- Parameters:
who
- the user being queriedcap
- The security capability in question
- Returns:
- true, only if the user has the given capability