org.alfresco.repo.node
Class NodeAuditor

java.lang.Object
  extended by org.alfresco.repo.node.NodeAuditor
All Implemented Interfaces:
NodeServicePolicies.BeforeDeleteNodePolicy, ClassPolicy, Policy, org.springframework.beans.factory.InitializingBean

public class NodeAuditor
extends java.lang.Object
implements org.springframework.beans.factory.InitializingBean, NodeServicePolicies.BeforeDeleteNodePolicy

A listener that ensures that an event is audited for every deleted node in a tree of nodes, not just the top one captured by AuditMethodInterceptor! The values passed to the audit component are:

 /alfresco-node
    /beforeDeleteNode
       /node=<nodeRef>
 
 


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.alfresco.repo.policy.Policy
Policy.Arg
 
Field Summary
 
Fields inherited from interface org.alfresco.repo.node.NodeServicePolicies.BeforeDeleteNodePolicy
QNAME
 
Fields inherited from interface org.alfresco.repo.policy.Policy
NAMESPACE
 
Constructor Summary
NodeAuditor()
           
 
Method Summary
 void afterPropertiesSet()
          Checks that all necessary properties have been set and binds with the policy component.
 void beforeDeleteNode(org.alfresco.service.cmr.repository.NodeRef nodeRef)
          Called before a node is deleted.
 void setAuditComponent(AuditComponent auditComponent)
          The component to create audit events
 void setPolicyComponent(PolicyComponent policyComponent)
          Set the component used to bind to behaviour callbacks
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NodeAuditor

public NodeAuditor()
Method Detail

setPolicyComponent

public void setPolicyComponent(PolicyComponent policyComponent)
Set the component used to bind to behaviour callbacks


setAuditComponent

public void setAuditComponent(AuditComponent auditComponent)
The component to create audit events


afterPropertiesSet

public void afterPropertiesSet()
Checks that all necessary properties have been set and binds with the policy component.

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

beforeDeleteNode

public void beforeDeleteNode(org.alfresco.service.cmr.repository.NodeRef nodeRef)
Description copied from interface: NodeServicePolicies.BeforeDeleteNodePolicy
Called before a node is deleted.

Specified by:
beforeDeleteNode in interface NodeServicePolicies.BeforeDeleteNodePolicy
Parameters:
nodeRef - the node reference


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