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

Quick Search    Search Deep

org.acegisecurity
Interface AfterInvocationManager  view AfterInvocationManager download AfterInvocationManager.java


public interface AfterInvocationManager

Reviews the Object returned from a secure object invocation, being able to modify the Object or throw an AccessDeniedException.

Typically used to ensure the principal is permitted to access the domain object instance returned by a service layer bean. Can also be used to mutate the domain object instance so the principal is only able to access authorised bean properties or Collection elements. Often used in conjunction with an org.acegisecurity.acl.AclManager to obtain the access control list applicable for the domain object instance.

Special consideration should be given to using an AfterInvocationManager on bean methods that modify a database. Typically an AfterInvocationManager is used with read-only methods, such as public DomainObject getById(id). If used with methods that modify a database, a transaction manager should be used to ensure any AccessDeniedException will cause a rollback of the changes made by the transaction.

Version:
$Id: AfterInvocationManager.java,v 1.2 2005/11/17 00:55:49 benalex Exp $

Method Summary
 java.lang.Object decide(Authentication authentication, java.lang.Object object, ConfigAttributeDefinition config, java.lang.Object returnedObject)
          Given the details of a secure object invocation including its returned Object, make an access control decision or optionally modify the returned Object.
 boolean supports(ConfigAttribute attribute)
          Indicates whether this AfterInvocationManager is able to process "after invocation" requests presented with the passed ConfigAttribute.
 

Method Detail

decide

public java.lang.Object decide(Authentication authentication,
                               java.lang.Object object,
                               ConfigAttributeDefinition config,
                               java.lang.Object returnedObject)
                        throws AccessDeniedException
Given the details of a secure object invocation including its returned Object, make an access control decision or optionally modify the returned Object.


supports

public boolean supports(ConfigAttribute attribute)
Indicates whether this AfterInvocationManager is able to process "after invocation" 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.