org.alfresco.repo.security.permissions.impl.acegi
Class ACLEntryVoter

java.lang.Object
  extended by org.alfresco.repo.security.permissions.impl.acegi.ACLEntryVoter
All Implemented Interfaces:
net.sf.acegisecurity.vote.AccessDecisionVoter, org.springframework.beans.factory.InitializingBean

public class ACLEntryVoter
extends java.lang.Object
implements net.sf.acegisecurity.vote.AccessDecisionVoter, org.springframework.beans.factory.InitializingBean


Field Summary
 
Fields inherited from interface net.sf.acegisecurity.vote.AccessDecisionVoter
ACCESS_ABSTAIN, ACCESS_DENIED, ACCESS_GRANTED
 
Constructor Summary
ACLEntryVoter()
          Default constructor
 
Method Summary
 void afterPropertiesSet()
           
 org.alfresco.service.namespace.NamespacePrefixResolver getNamespacePrefixResolver()
          Get the name space prefix resolver
 org.alfresco.service.cmr.repository.NodeService getNodeService()
          Get the node service
 org.alfresco.service.cmr.security.PermissionService getPermissionService()
          Get the permission service
 void setAbstainFor(java.util.Set abstainFor)
          Types and aspects for which we will abstain on voting if they are present.
 void setAuthenticationService(AuthenticationService authenticationService)
          Set the authentication service
 void setAuthorityService(AuthorityService authorityService)
          Set the authority service
 void setNamespacePrefixResolver(org.alfresco.service.namespace.NamespacePrefixResolver nspr)
          Set the name space prefix resolver
 void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
          Set the node service
 void setPermissionService(org.alfresco.service.cmr.security.PermissionService permissionService)
          Set the permission service
 boolean supports(java.lang.Class clazz)
          This implementation supports only MethodSecurityInterceptor, because it queries the presented MethodInvocation.
 boolean supports(net.sf.acegisecurity.ConfigAttribute attribute)
           
 int vote(net.sf.acegisecurity.Authentication authentication, java.lang.Object object, net.sf.acegisecurity.ConfigAttributeDefinition config)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ACLEntryVoter

public ACLEntryVoter()
Default constructor

Method Detail

setPermissionService

public void setPermissionService(org.alfresco.service.cmr.security.PermissionService permissionService)
Set the permission service

Parameters:
permissionService -

getPermissionService

public org.alfresco.service.cmr.security.PermissionService getPermissionService()
Get the permission service

Returns:
the permission service

getNamespacePrefixResolver

public org.alfresco.service.namespace.NamespacePrefixResolver getNamespacePrefixResolver()
Get the name space prefix resolver

Returns:
the name space prefix resolver

setNamespacePrefixResolver

public void setNamespacePrefixResolver(org.alfresco.service.namespace.NamespacePrefixResolver nspr)
Set the name space prefix resolver

Parameters:
nspr -

getNodeService

public org.alfresco.service.cmr.repository.NodeService getNodeService()
Get the node service

Returns:
the node service

setNodeService

public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
Set the node service

Parameters:
nodeService -

setAuthenticationService

public void setAuthenticationService(AuthenticationService authenticationService)
Set the authentication service

Parameters:
authenticationService -

setAuthorityService

public void setAuthorityService(AuthorityService authorityService)
Set the authority service

Parameters:
authorityService -

setAbstainFor

public void setAbstainFor(java.util.Set abstainFor)
Types and aspects for which we will abstain on voting if they are present.

Parameters:
abstainFor -

afterPropertiesSet

public void afterPropertiesSet()
                        throws java.lang.Exception
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Throws:
java.lang.Exception

supports

public boolean supports(net.sf.acegisecurity.ConfigAttribute attribute)
Specified by:
supports in interface net.sf.acegisecurity.vote.AccessDecisionVoter

supports

public boolean supports(java.lang.Class clazz)
This implementation supports only MethodSecurityInterceptor, because it queries the presented MethodInvocation.

Specified by:
supports in interface net.sf.acegisecurity.vote.AccessDecisionVoter
Parameters:
clazz - the secure object
Returns:
true if the secure object is MethodInvocation, false otherwise

vote

public int vote(net.sf.acegisecurity.Authentication authentication,
                java.lang.Object object,
                net.sf.acegisecurity.ConfigAttributeDefinition config)
Specified by:
vote in interface net.sf.acegisecurity.vote.AccessDecisionVoter


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.