Class PdxInstanceMethodInterceptor
java.lang.Object
org.springframework.data.gemfire.search.lucene.support.PdxInstanceMethodInterceptor
- All Implemented Interfaces:
Advice
,Interceptor
,MethodInterceptor
The
PdxInstanceMethodInterceptor
class is a MethodInterceptor
wrapping a PdxInstance
to back a proxy during intercepted method invocations.- Since:
- 1.1.0
- Author:
- John Blum
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs an instance ofPdxInstanceMethodInterceptor
initialized with the givensource
. -
Method Summary
Modifier and TypeMethodDescriptionprotected PdxInstance
Returns thesource
backing the proxy for intercepted method invocations.invoke
(MethodInvocation invocation) static PdxInstanceMethodInterceptor
Factory method used to construct an instance ofPdxInstanceMethodInterceptor
initialized with the givensource
.static PdxInstanceMethodInterceptor
Factory method used to construct an instance ofPdxInstanceMethodInterceptor
initialized with the givenPdxInstance
.
-
Constructor Details
-
PdxInstanceMethodInterceptor
Constructs an instance ofPdxInstanceMethodInterceptor
initialized with the givensource
.- Parameters:
source
-PdxInstance
used as the source to back the proxy in method invocations.- Throws:
IllegalArgumentException
- ifsource
is null.- See Also:
-
-
Method Details
-
newPdxInstanceMethodInterceptor
Factory method used to construct an instance ofPdxInstanceMethodInterceptor
initialized with the givensource
.- Parameters:
source
-Object
serving as the source to back the proxy in method invocations. Source must be an instance ofPdxInstance
.- Returns:
- a new instance of
PdxInstanceMethodInterceptor
initialized with the givensource
. - Throws:
IllegalArgumentException
- ifsource
is not an instance ofPdxInstance
.- See Also:
-
newPdxInstanceMethodInterceptor
Factory method used to construct an instance ofPdxInstanceMethodInterceptor
initialized with the givenPdxInstance
.- Parameters:
source
-PdxInstance
serving as the source to back the proxy in method invocations. Source must not be null.- Returns:
- a new instance of
PdxInstanceMethodInterceptor
initialized with the givensource
. - Throws:
IllegalArgumentException
- ifsource
is null.- See Also:
-
getSource
Returns thesource
backing the proxy for intercepted method invocations.- Returns:
- the
source
backing the proxy for intercepted method invocations. - See Also:
-
invoke
- Specified by:
invoke
in interfaceMethodInterceptor
- Throws:
Throwable
-