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

Quick Search    Search Deep

net.sf.acegisecurity.intercept.method.aspectj
Class AspectJSecurityInterceptor  view AspectJSecurityInterceptor download AspectJSecurityInterceptor.java

java.lang.Object
  extended bynet.sf.acegisecurity.intercept.AbstractSecurityInterceptor
      extended bynet.sf.acegisecurity.intercept.method.aspectj.AspectJSecurityInterceptor
All Implemented Interfaces:
org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.InitializingBean

public class AspectJSecurityInterceptor
extends net.sf.acegisecurity.intercept.AbstractSecurityInterceptor

Provides security interception of AspectJ method invocations.

The ObjectDefinitionSource required by this security interceptor is of type net.sf.acegisecurity.intercept.method.MethodDefinitionSource. This is shared with the AOP Alliance based security interceptor (MethodSecurityInterceptor), since both work with Java Methods.

The secure object type is org.aspectj.lang.JoinPoint, which is passed from the relevant around() advice. The around() advice also passes an anonymous implementation of AspectJCallback which contains the call for AspectJ to continue processing: return proceed();.

Refer to net.sf.acegisecurity.intercept.AbstractSecurityInterceptor for details on the workflow.

Version:
$Id: AspectJSecurityInterceptor.java,v 1.2 2004/11/15 01:43:47 benalex Exp $

Field Summary
private  net.sf.acegisecurity.intercept.method.MethodDefinitionSource objectDefinitionSource
           
 
Fields inherited from class net.sf.acegisecurity.intercept.AbstractSecurityInterceptor
logger
 
Constructor Summary
AspectJSecurityInterceptor()
           
 
Method Summary
 net.sf.acegisecurity.intercept.method.MethodDefinitionSource getObjectDefinitionSource()
           
 java.lang.Class getSecureObjectClass()
          Indicates the type of secure objects the subclass will be presenting to the abstract parent for processing.
 java.lang.Object invoke(JoinPoint jp, AspectJCallback advisorProceed)
          This method should be used to enforce security on a JoinPoint.
 net.sf.acegisecurity.intercept.ObjectDefinitionSource obtainObjectDefinitionSource()
           
 void setObjectDefinitionSource(net.sf.acegisecurity.intercept.method.MethodDefinitionSource newSource)
           
 
Methods inherited from class net.sf.acegisecurity.intercept.AbstractSecurityInterceptor
afterInvocation, afterPropertiesSet, beforeInvocation, getAccessDecisionManager, getAfterInvocationManager, getAuthenticationManager, getRunAsManager, isValidateConfigAttributes, setAccessDecisionManager, setAfterInvocationManager, setApplicationContext, setAuthenticationManager, setRunAsManager, setValidateConfigAttributes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

objectDefinitionSource

private net.sf.acegisecurity.intercept.method.MethodDefinitionSource objectDefinitionSource
Constructor Detail

AspectJSecurityInterceptor

public AspectJSecurityInterceptor()
Method Detail

setObjectDefinitionSource

public void setObjectDefinitionSource(net.sf.acegisecurity.intercept.method.MethodDefinitionSource newSource)

getObjectDefinitionSource

public net.sf.acegisecurity.intercept.method.MethodDefinitionSource getObjectDefinitionSource()

getSecureObjectClass

public java.lang.Class getSecureObjectClass()
Description copied from class: net.sf.acegisecurity.intercept.AbstractSecurityInterceptor
Indicates the type of secure objects the subclass will be presenting to the abstract parent for processing. This is used to ensure collaborators wired to the AbstractSecurityInterceptor all support the indicated secure object class.


invoke

public java.lang.Object invoke(JoinPoint jp,
                               AspectJCallback advisorProceed)
This method should be used to enforce security on a JoinPoint.


obtainObjectDefinitionSource

public net.sf.acegisecurity.intercept.ObjectDefinitionSource obtainObjectDefinitionSource()