Package org.apache.wiki.ui
Class GroupCommand
- java.lang.Object
-
- org.apache.wiki.ui.AbstractCommand
-
- org.apache.wiki.ui.GroupCommand
-
- All Implemented Interfaces:
Command
public final class GroupCommand extends AbstractCommand
Defines Commands for viewing, editing and deleting wiki groups. GroupCommands can be combined with GroupPrincipals to produce targeted Commands.
This class is not
final; it may be extended in the future.- Since:
- 2.4.22
-
-
Field Summary
Fields Modifier and Type Field Description static CommandDELETE_GROUPGroupCommand for deleting a group.static CommandEDIT_GROUPGroupCommand for editing a group.static CommandVIEW_GROUPGroupCommand for viewing a group.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetName()Returns the name of the command, which will either be the target (if specified), or the "friendly name" for the JSP.java.security.PermissionrequiredPermission()Returns the permission required to execute this GroupCommand.CommandtargetedCommand(java.lang.Object target)Creates and returns a targeted Command by combining a GroupPrincipal with this Command.-
Methods inherited from class org.apache.wiki.ui.AbstractCommand
getContentTemplate, getJSP, getJSPFriendlyName, getRequestContext, getTarget, getURLPattern, toString
-
-
-
-
Field Detail
-
DELETE_GROUP
public static final Command DELETE_GROUP
GroupCommand for deleting a group.
-
EDIT_GROUP
public static final Command EDIT_GROUP
GroupCommand for editing a group.
-
VIEW_GROUP
public static final Command VIEW_GROUP
GroupCommand for viewing a group.
-
-
Method Detail
-
targetedCommand
public Command targetedCommand(java.lang.Object target)
Creates and returns a targeted Command by combining a GroupPrincipal with this Command. The suppliedtargetobject must be non-nulland of type GroupPrincipal. If the target is not of the correct type, this method throws anIllegalArgumentException.- Specified by:
targetedCommandin interfaceCommand- Specified by:
targetedCommandin classAbstractCommand- Parameters:
target- the GroupPrincipal to combine into the current Command- Returns:
- the new, targeted command
- See Also:
Command.targetedCommand(Object)
-
getName
public java.lang.String getName()
Returns the name of the command, which will either be the target (if specified), or the "friendly name" for the JSP.- Specified by:
getNamein interfaceCommand- Specified by:
getNamein classAbstractCommand- Returns:
- the name
- See Also:
Command.getName()
-
requiredPermission
public java.security.Permission requiredPermission()
Returns the permission required to execute this GroupCommand.- Returns:
- the permission
- See Also:
Command.requiredPermission()
-
-