Package org.webharvest.ioc
Class ScrapingInterceptor
- java.lang.Object
-
- org.webharvest.ioc.ScrapingInterceptor
-
- All Implemented Interfaces:
org.aopalliance.aop.Advice
,org.aopalliance.intercept.Interceptor
,org.aopalliance.intercept.MethodInterceptor
public final class ScrapingInterceptor extends Object implements org.aopalliance.intercept.MethodInterceptor
Guice AOP interceptor responsible for taking action for method annotated withScraping
annotation. New scraping scope is created for each annotated method and is persistent until the end of invocation. Only ancestors ofHarvester
are applicable. An attempt to apply scraping scope to any other type will end up with thrownIllegalStateException
. Just after the scope is created and shortly before it is left all registeredScrapingAware
listeners are notified about the lifecycle change.- Since:
- 2.1.0-SNAPSHOT
- Version:
- %I%, %G%
- Author:
- Robert Bala
- See Also:
Scraping
,MethodInterceptor
,ScrapingAware
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ScrapingInterceptor.ScrapingAwareHelper
Guice aware helper class that maintains collection of registeredScrapingAware
listeners.
-
Constructor Summary
Constructors Constructor Description ScrapingInterceptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
invoke(org.aopalliance.intercept.MethodInvocation invocation)
-