Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.acegisecurity.vote
Class AbstractAccessDecisionManager  view AbstractAccessDecisionManager download AbstractAccessDecisionManager.java

java.lang.Object
  extended byorg.acegisecurity.vote.AbstractAccessDecisionManager
All Implemented Interfaces:
org.acegisecurity.AccessDecisionManager, org.springframework.beans.factory.InitializingBean, org.springframework.context.MessageSourceAware
Direct Known Subclasses:
AffirmativeBased, ConsensusBased, UnanimousBased

public abstract class AbstractAccessDecisionManager
extends java.lang.Object
implements org.acegisecurity.AccessDecisionManager, org.springframework.beans.factory.InitializingBean, org.springframework.context.MessageSourceAware

Abstract implementation of org.acegisecurity.AccessDecisionManager.

Handles configuration of a bean context defined list of AccessDecisionVoters and the access control behaviour if all voters abstain from voting (defaults to deny access).


Field Summary
private  boolean allowIfAllAbstainDecisions
           
private  java.util.List decisionVoters
           
protected  org.springframework.context.support.MessageSourceAccessor messages
           
 
Constructor Summary
AbstractAccessDecisionManager()
           
 
Method Summary
 void afterPropertiesSet()
          Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware).
private  void checkIfValidList(java.util.List listToCheck)
           
 java.util.List getDecisionVoters()
           
 boolean isAllowIfAllAbstainDecisions()
           
 void setAllowIfAllAbstainDecisions(boolean allowIfAllAbstainDecisions)
           
 void setDecisionVoters(java.util.List newList)
           
 void setMessageSource(org.springframework.context.MessageSource messageSource)
          Set the MessageSource that this object runs in.
 boolean supports(ConfigAttribute attribute)
          Indicates whether this AccessDecisionManager is able to process authorization requests presented with the passed ConfigAttribute.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.acegisecurity.AccessDecisionManager
decide
 

Field Detail

decisionVoters

private java.util.List decisionVoters

messages

protected org.springframework.context.support.MessageSourceAccessor messages

allowIfAllAbstainDecisions

private boolean allowIfAllAbstainDecisions
Constructor Detail

AbstractAccessDecisionManager

public AbstractAccessDecisionManager()
Method Detail

afterPropertiesSet

public void afterPropertiesSet()
                        throws java.lang.Exception
Description copied from interface: org.springframework.beans.factory.InitializingBean
Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware).

This method allows the bean instance to perform initialization only possible when all bean properties have been set and to throw an exception in the event of misconfiguration.

Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean

checkIfValidList

private void checkIfValidList(java.util.List listToCheck)

getDecisionVoters

public java.util.List getDecisionVoters()

isAllowIfAllAbstainDecisions

public boolean isAllowIfAllAbstainDecisions()

setAllowIfAllAbstainDecisions

public void setAllowIfAllAbstainDecisions(boolean allowIfAllAbstainDecisions)

setDecisionVoters

public void setDecisionVoters(java.util.List newList)

setMessageSource

public void setMessageSource(org.springframework.context.MessageSource messageSource)
Description copied from interface: org.springframework.context.MessageSourceAware
Set the MessageSource that this object runs in.

Invoked after population of normal bean properties but before an init callback like InitializingBean's afterPropertiesSet or a custom init-method. Invoked before ApplicationContextAware's setApplicationContext.

Specified by:
setMessageSource in interface org.springframework.context.MessageSourceAware

supports

public boolean supports(ConfigAttribute attribute)
Description copied from interface: org.acegisecurity.AccessDecisionManager
Indicates whether this AccessDecisionManager is able to process authorization requests presented with the passed ConfigAttribute.

This allows the AbstractSecurityInterceptor to check every configuration attribute can be consumed by the configured AccessDecisionManager and/or RunAsManager and/or AfterInvocationManager.

Specified by:
supports in interface org.acegisecurity.AccessDecisionManager