org.granite.tide.spring
Class TideDataPublishingInterceptor

java.lang.Object
  extended by org.granite.tide.spring.TideDataPublishingInterceptor
All Implemented Interfaces:
org.aopalliance.aop.Advice, org.aopalliance.intercept.Interceptor, org.aopalliance.intercept.MethodInterceptor

public class TideDataPublishingInterceptor
extends Object
implements org.aopalliance.intercept.MethodInterceptor

Spring AOP interceptor to handle publishing of data changes instead of relying on the default behaviour This can be used outside of a HTTP Granite context and inside the security/transaction context Ensure that the order of the interceptor is correctly setup to use ON_COMMIT publish mode: this interceptor must be executed inside a transaction

Author:
William DRAI

Constructor Summary
TideDataPublishingInterceptor()
           
 
Method Summary
 Object invoke(org.aopalliance.intercept.MethodInvocation invocation)
           
 void setDataUpdatePostprocessor(org.granite.tide.data.DataUpdatePostprocessor dataUpdatePostprocessor)
           
 void setGravity(org.granite.gravity.Gravity gravity)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TideDataPublishingInterceptor

public TideDataPublishingInterceptor()
Method Detail

setGravity

public void setGravity(org.granite.gravity.Gravity gravity)

setDataUpdatePostprocessor

@Autowired(required=false)
public void setDataUpdatePostprocessor(org.granite.tide.data.DataUpdatePostprocessor dataUpdatePostprocessor)

invoke

public Object invoke(org.aopalliance.intercept.MethodInvocation invocation)
              throws Throwable
Specified by:
invoke in interface org.aopalliance.intercept.MethodInterceptor
Throws:
Throwable