Package com.uc4.api.objects
Class UserPrivileges
- java.lang.Object
-
- com.uc4.api.objects.UserPrivileges
-
public class UserPrivileges extends java.lang.Object
This class represents the privileges of a user. It serves to allow or to deny the User access to system functions. Privileges are an integral part of the Authorization System.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
UserPrivileges.Privilege
Enumeration of all Privileges.
-
Constructor Summary
Constructors Modifier Constructor Description protected
UserPrivileges(com.uc4.util.XMLDocument doc)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isPrivilegeSet(UserPrivileges.Privilege priv)
Returnstrue
if the specified privilege is enabled.void
selectAll()
Enables all NOT deprecated privileges.void
setPrivilege(UserPrivileges.Privilege priv, boolean value)
Sets or clears a privilege.protected void
store(com.uc4.util.XMLDocument doc, org.w3c.dom.Element objectElement)
void
unselectAll()
Disables all privileges.
-
-
-
Method Detail
-
store
protected void store(com.uc4.util.XMLDocument doc, org.w3c.dom.Element objectElement)
-
isPrivilegeSet
public boolean isPrivilegeSet(UserPrivileges.Privilege priv)
Returnstrue
if the specified privilege is enabled.- Parameters:
priv
- Privilege- Returns:
true
if enabled,false
otherwise
-
setPrivilege
public void setPrivilege(UserPrivileges.Privilege priv, boolean value)
Sets or clears a privilege.- Parameters:
priv
- Enum constantvalue
-true
to enable the privilege,false
to disable it
-
selectAll
public void selectAll()
Enables all NOT deprecated privileges.
-
unselectAll
public void unselectAll()
Disables all privileges.
-
-