com.softwareag.centrasite.appl.framework.validation.acl
Class DefaultAclController

java.lang.Object
  extended by com.softwareag.centrasite.appl.framework.validation.acl.DefaultAclController
All Implemented Interfaces:
AclController

public class DefaultAclController
extends java.lang.Object
implements AclController

Default implementation of AclController. The controller takes as input an XML file, which specifies the access control lists.


Constructor Summary
DefaultAclController(com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext, DefaultAclControllerConfiguration pConfiguration)
          Creates a new instance, which matches the given configuration.
 
Method Summary
 void assertGranted(AclContext pContext, java.lang.String pId)
          Called to asser, that access is granted.
protected  com.softwareag.centrasite.appl.framework.validation.acl.DefaultAcl createAcl(java.util.Map<java.lang.String,AclProvider> pProviders, com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext, Acl pAcl)
          Called to create an instance of DefaultAcl, which meets the given configuration.
protected  com.softwareag.centrasite.appl.framework.validation.acl.DefaultAction createAction(java.util.Map<java.lang.String,com.softwareag.centrasite.appl.framework.validation.acl.DefaultAcl> pAcls, com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext, Action pAction)
          Called to create an instance of DefaultAction, which meets the given configuration.
protected  AclProvider createProvider(com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext, Provider pProvider)
          Called to create an instance of AclProvider, which meets the given configuration.
 boolean isDenied(AclContext pContext, java.lang.String pId)
          Called to query, whether access is denied.
 boolean isGranted(AclContext pContext, java.lang.String pId)
          Called to query, whether access is granted.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultAclController

public DefaultAclController(com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext,
                            DefaultAclControllerConfiguration pConfiguration)
                     throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Creates a new instance, which matches the given configuration.

Parameters:
pContext - This context is used to initialize the objects created by the controller. This applies, in particular, to the instances of AclProvider.
pConfiguration - The controllers configuration.
Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Method Detail

createAction

protected com.softwareag.centrasite.appl.framework.validation.acl.DefaultAction createAction(java.util.Map<java.lang.String,com.softwareag.centrasite.appl.framework.validation.acl.DefaultAcl> pAcls,
                                                                                             com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext,
                                                                                             Action pAction)
                                                                                      throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Called to create an instance of DefaultAction, which meets the given configuration.

Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException

createProvider

protected AclProvider createProvider(com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext,
                                     Provider pProvider)
                              throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Called to create an instance of AclProvider, which meets the given configuration.

Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException

createAcl

protected com.softwareag.centrasite.appl.framework.validation.acl.DefaultAcl createAcl(java.util.Map<java.lang.String,AclProvider> pProviders,
                                                                                       com.softwareag.centrasite.appl.framework.ioc.IOCProvider pContext,
                                                                                       Acl pAcl)
                                                                                throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Called to create an instance of DefaultAcl, which meets the given configuration.

Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException

assertGranted

public void assertGranted(AclContext pContext,
                          java.lang.String pId)
                   throws CSAppAuthenticationException,
                          com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Description copied from interface: AclController
Called to asser, that access is granted.

Specified by:
assertGranted in interface AclController
Parameters:
pContext - The object, which is specifying the access requestor
pId - Id of the object, to which access is requested.
Throws:
CSAppAuthenticationException - The assertion failed, because access is denied.
com.softwareag.centrasite.appl.framework.CSAppFrameworkException
See Also:
AclController.isGranted(AclContext, String)

isDenied

public boolean isDenied(AclContext pContext,
                        java.lang.String pId)
                 throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Description copied from interface: AclController
Called to query, whether access is denied.

Specified by:
isDenied in interface AclController
Parameters:
pContext - The object, which is specifying the access requester.
pId - Id of the object, to which access is requested.
Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException
See Also:
AclController.isGranted(AclContext, String)

isGranted

public boolean isGranted(AclContext pContext,
                         java.lang.String pId)
                  throws com.softwareag.centrasite.appl.framework.CSAppFrameworkException
Description copied from interface: AclController
Called to query, whether access is granted.

Specified by:
isGranted in interface AclController
Parameters:
pContext - The object, which is specifying the access requester.
pId - Id of the object, to which access is requested.
Throws:
com.softwareag.centrasite.appl.framework.CSAppFrameworkException
See Also:
AclController.isDenied(AclContext, String)