org.mmbase.security
Class Action

java.lang.Object
  extended by org.mmbase.security.Action
All Implemented Interfaces:
Serializable

public class Action
extends Object
implements Serializable

An action is something which an authenticated user may want to do, but which is not directly associated with MMBase nodes. Actions are e.g. provided by Components (and can be added to component XML's). Actions are checked using Authorization.check(UserContext, Action, Parameters). Action instances can be retrieved with the ActionRepository.

Since:
MMBase-1.9
Version:
$Id: Action.java 39192 2009-10-18 07:53:58Z michiel $
Author:
Michiel Meeuwissen
See Also:
Serialized Form

Field Summary
protected  ActionChecker defaultChecker
           
protected  LocalizedString description
           
protected  String name
           
protected  String nameSpace
           
 
Constructor Summary
Action(String ns, String n, ActionChecker c)
           
 
Method Summary
 Parameters createParameters()
           
 ActionChecker getDefault()
          Every action needs to do a proposal on how to check it.
 LocalizedString getDescription()
           
 String getName()
          Every action has a non-null name.
 String getNameSpace()
          Most 'actions' have a namespace.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

protected final String name

description

protected final LocalizedString description

defaultChecker

protected final ActionChecker defaultChecker

nameSpace

protected final String nameSpace
Constructor Detail

Action

public Action(String ns,
              String n,
              ActionChecker c)
Method Detail

getDefault

public ActionChecker getDefault()
Every action needs to do a proposal on how to check it. The security implementation may override this. But since components can freely define new actions, which may not be anticipated by the authorization implementation, the action itself must provide some basic checker (e.g. an instance of ActionChecker.Rank).


getName

public String getName()
Every action has a non-null name. Together with the getNameSpace() it uniquely identifies the action.


getNameSpace

public String getNameSpace()
Most 'actions' have a namespace. This is normally identical to the name of the component with which they are associated. It can be null though.


getDescription

public LocalizedString getDescription()

toString

public String toString()
Overrides:
toString in class Object

createParameters

public Parameters createParameters()
See Also:
Authorization.check(UserContext, Action, Parameters)


MMBase 2.0-SNAPSHOT - null