| java.lang.Object java.security.Permission com.ecyrd.jspwiki.auth.permissions.WikiPermission
WikiPermission | final public class WikiPermission extends Permission (Code) | | Permission to perform an global wiki operation, such as self-registering
or creating new pages. Permission actions include: createGroups ,
createPages , editPreferences ,
editProfile and login . The target is
a given wiki. The syntax for the target is the wiki name. "All wikis" can be
specified using a wildcard (*). Page collections may also be specified using
a wildcard. For pages, the wildcard may be a prefix, suffix, or all by
itself. Certain permissions imply others. Currently,
createGroups implies createPages .
author: Andrew Jaquith since: 2.3 |
Constructor Summary | |
public | WikiPermission(String wiki, String actions) Creates a new WikiPermission for a specified set of actions. |
Method Summary | |
final protected static int | createMask(String actions) Private method that creates a binary mask based on the actions specified. | final public boolean | equals(Object obj) Two WikiPermission objects are considered equal if their wikis and
actions (after normalization) are equal. | final public String | getActions() Returns the actions for this permission: "createGroups", "createPages",
"editPreferences", "editProfile", or "login". | final public String | getWiki() Returns the name of the wiki containing the page represented by this
permission; may return the wildcard string. | final public int | hashCode() Returns the hash code for this WikiPermission. | final protected static int | impliedMask(int mask) Creates an "implied mask" based on the actions originally assigned: for
example, createGroups implies createPages . | final public boolean | implies(Permission permission) WikiPermission can only imply other WikiPermissions; no other permission
types are implied. | public PermissionCollection | newPermissionCollection() Returns a new
AllPermissionCollection . | final public String | toString() Prints a human-readable representation of this permission. |
CREATE_GROUPS_ACTION | final public static String CREATE_GROUPS_ACTION(Code) | | |
CREATE_GROUPS_MASK | final protected static int CREATE_GROUPS_MASK(Code) | | |
CREATE_PAGES_ACTION | final public static String CREATE_PAGES_ACTION(Code) | | |
CREATE_PAGES_MASK | final protected static int CREATE_PAGES_MASK(Code) | | |
EDIT_PREFERENCES_ACTION | final public static String EDIT_PREFERENCES_ACTION(Code) | | |
EDIT_PREFERENCES_MASK | final protected static int EDIT_PREFERENCES_MASK(Code) | | |
EDIT_PROFILE_ACTION | final public static String EDIT_PROFILE_ACTION(Code) | | |
EDIT_PROFILE_MASK | final protected static int EDIT_PROFILE_MASK(Code) | | |
LOGIN_MASK | final protected static int LOGIN_MASK(Code) | | |
WikiPermission | public WikiPermission(String wiki, String actions)(Code) | | Creates a new WikiPermission for a specified set of actions.
Parameters: actions - the actions for this permission |
createMask | final protected static int createMask(String actions)(Code) | | Private method that creates a binary mask based on the actions specified.
This is used by
WikiPermission.implies(Permission) .
Parameters: actions - the permission actions, separated by commas binary mask representing the permissions |
getActions | final public String getActions()(Code) | | Returns the actions for this permission: "createGroups", "createPages",
"editPreferences", "editProfile", or "login". The actions
will always be sorted in alphabetic order, and will always appear in
lower case.
the actions See Also: java.security.Permission.getActions |
getWiki | final public String getWiki()(Code) | | Returns the name of the wiki containing the page represented by this
permission; may return the wildcard string.
the wiki |
impliedMask | final protected static int impliedMask(int mask)(Code) | | Creates an "implied mask" based on the actions originally assigned: for
example, createGroups implies createPages .
Parameters: mask - the initial mask the implied mask |
implies | final public boolean implies(Permission permission)(Code) | | WikiPermission can only imply other WikiPermissions; no other permission
types are implied. One WikiPermission implies another if all of the other
WikiPermission's actions are equal to, or a subset of, those for this
permission.
Parameters: permission - the permission which may (or may not) be implied bythis instance true if the permission is implied,false otherwise See Also: java.security.Permission.implies(java.security.Permission) |
|
|