org.apache.lenya.cms.cocoon.acting
Class DelegatingAuthorizerAction

java.lang.Object
  extended by org.apache.avalon.framework.logger.AbstractLogEnabled
      extended by org.apache.cocoon.acting.AbstractAction
          extended by org.apache.cocoon.acting.AbstractConfigurableAction
              extended by org.apache.cocoon.acting.ConfigurableServiceableAction
                  extended by org.apache.lenya.cms.cocoon.acting.AccessControlAction
                      extended by org.apache.lenya.cms.cocoon.acting.DelegatingAuthorizerAction
All Implemented Interfaces:
org.apache.avalon.excalibur.pool.Poolable, org.apache.avalon.framework.component.Component, org.apache.avalon.framework.configuration.Configurable, org.apache.avalon.framework.logger.LogEnabled, org.apache.avalon.framework.service.Serviceable, org.apache.cocoon.acting.Action

public class DelegatingAuthorizerAction
extends AccessControlAction
implements org.apache.avalon.excalibur.pool.Poolable

AuthorizerAction that delegates the authorizing to an AccessController.


Field Summary
static java.lang.String HISTORY
          HISTORY Name of the session attribute that holds the history
 
Fields inherited from class org.apache.cocoon.acting.ConfigurableServiceableAction
manager
 
Fields inherited from class org.apache.cocoon.acting.AbstractConfigurableAction
settings
 
Fields inherited from class org.apache.cocoon.acting.AbstractAction
EMPTY_MAP
 
Fields inherited from interface org.apache.cocoon.acting.Action
ROLE
 
Constructor Summary
DelegatingAuthorizerAction()
           
 
Method Summary
 java.util.Map act(org.apache.cocoon.environment.Redirector redirector, org.apache.cocoon.environment.SourceResolver resolver, java.util.Map objectModel, java.lang.String src, org.apache.avalon.framework.parameters.Parameters parameters)
           Invokes the access control functionality.
protected  java.util.Map doAct(org.apache.cocoon.environment.Redirector redirector, org.apache.cocoon.environment.SourceResolver resolver, java.util.Map objectModel, java.lang.String source, org.apache.avalon.framework.parameters.Parameters parameters)
          The actual act method.
protected  void setHistory(org.apache.cocoon.environment.Request request)
          Adds the current URL to the history.
 
Methods inherited from class org.apache.lenya.cms.cocoon.acting.AccessControlAction
getAccessController
 
Methods inherited from class org.apache.cocoon.acting.ConfigurableServiceableAction
service
 
Methods inherited from class org.apache.cocoon.acting.AbstractConfigurableAction
configure
 
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HISTORY

public static final java.lang.String HISTORY
HISTORY Name of the session attribute that holds the history

Constructor Detail

DelegatingAuthorizerAction

public DelegatingAuthorizerAction()
Method Detail

act

public java.util.Map act(org.apache.cocoon.environment.Redirector redirector,
                         org.apache.cocoon.environment.SourceResolver resolver,
                         java.util.Map objectModel,
                         java.lang.String src,
                         org.apache.avalon.framework.parameters.Parameters parameters)
                  throws java.lang.Exception
Description copied from class: AccessControlAction

Invokes the access control functionality. If no access controller was found for the requested URL, an empty map is returned.

This is a template method. Implement doAct() to add your functionality.

Specified by:
act in interface org.apache.cocoon.acting.Action
Overrides:
act in class AccessControlAction
Throws:
java.lang.Exception
See Also:
Action.act(org.apache.cocoon.environment.Redirector, org.apache.cocoon.environment.SourceResolver, java.util.Map, java.lang.String, org.apache.avalon.framework.parameters.Parameters)

doAct

protected java.util.Map doAct(org.apache.cocoon.environment.Redirector redirector,
                              org.apache.cocoon.environment.SourceResolver resolver,
                              java.util.Map objectModel,
                              java.lang.String source,
                              org.apache.avalon.framework.parameters.Parameters parameters)
                       throws java.lang.Exception
Description copied from class: AccessControlAction
The actual act method.

Specified by:
doAct in class AccessControlAction
Parameters:
redirector - The Redirector in charge
resolver - The SourceResolver in charge
objectModel - The Map with object of the calling environment which can be used to select values this controller may need (ie Request, Response).
source - A source String to the Action
parameters - The Parameters for this invocation
Returns:
Map The returned Map object with sitemap substitution values which can be used in subsequent elements attributes like src= using a xpath like expression: src="mydir/{myval}/foo" If the return value is null the processing inside the element of the sitemap will be skipped.
Throws:
java.lang.Exception - Indicates something is totally wrong
See Also:
AccessControlAction.doAct(org.apache.cocoon.environment.Redirector, org.apache.cocoon.environment.SourceResolver, java.util.Map, java.lang.String, org.apache.avalon.framework.parameters.Parameters)

setHistory

protected void setHistory(org.apache.cocoon.environment.Request request)
Adds the current URL to the history.

Parameters:
request - The request.


Copyright © $ Apache Software Foundation. All Rights Reserved.