public class GemfireFunctionProxyFactoryBean extends AbstractFactoryBeanSupport<Object> implements MethodInterceptor
FactoryBean
for all non-Region Function Execution interfaces.Method
,
MethodInterceptor
,
BeanClassLoaderAware
,
FactoryBean
,
AbstractFactoryBeanSupport
DEFAULT_SINGLETON
OBJECT_TYPE_ATTRIBUTE
Constructor and Description |
---|
GemfireFunctionProxyFactoryBean(Class<?> functionExecutionInterface,
GemfireFunctionOperations gemfireFunctionOperations)
Constructs a new instance of
GemfireFunctionProxyFactoryBean initialized with the given
Function Excution Interface and GemfireFunctionOperations . |
Modifier and Type | Method and Description |
---|---|
ClassLoader |
getBeanClassLoader()
Returns a reference to the
ClassLoader used by the Spring container to load bean classes . |
protected Class<?> |
getFunctionExecutionInterface() |
protected org.springframework.data.gemfire.function.execution.FunctionExecutionMethodMetadata<org.springframework.data.gemfire.function.execution.MethodMetadata> |
getFunctionExecutionMethodMetadata() |
protected GemfireFunctionOperations |
getGemfireFunctionOperations() |
Object |
getObject() |
Class<?> |
getObjectType() |
Object |
invoke(MethodInvocation invocation) |
protected Object |
invokeFunction(Method method,
Object[] args) |
protected boolean |
isFunctionExecutedOnSingleServerOrSingleMember(Method method) |
protected boolean |
isInstanceOfFunctionReturnType(MethodInvocation invocation,
Object value) |
protected boolean |
isIterable(Object value) |
protected boolean |
isNotInstanceOfFunctionReturnType(MethodInvocation invocation,
Object value) |
protected void |
onInit() |
protected Object |
resolveResult(MethodInvocation invocation,
Object result) |
protected Object |
resolveSingleResultIfPossible(Iterable<?> results) |
getBeanFactory, getBeanName, getLog, isSingleton, logDebug, logDebug, logError, logError, logInfo, logInfo, logWarning, logWarning, newLog, setBeanClassLoader, setBeanFactory, setBeanName
public GemfireFunctionProxyFactoryBean(@NonNull Class<?> functionExecutionInterface, @NonNull GemfireFunctionOperations gemfireFunctionOperations)
GemfireFunctionProxyFactoryBean
initialized with the given
Function Excution Interface
and GemfireFunctionOperations
.functionExecutionInterface
- Function Execution Interface
to proxy;
must not be null.gemfireFunctionOperations
- template used to execute the Function
.IllegalArgumentException
- if the Function Execution Interface
is null
or the Function Execution Type
is not an actual interface.GemfireFunctionOperations
@NonNull public ClassLoader getBeanClassLoader()
AbstractFactoryBeanSupport
ClassLoader
used by the Spring container to load bean classes
.getBeanClassLoader
in class AbstractFactoryBeanSupport<Object>
ClassLoader
used by the Spring container to load bean classes
.BeanClassLoaderAware.setBeanClassLoader(ClassLoader)
,
ClassLoader
,
Class
protected Class<?> getFunctionExecutionInterface()
@NonNull protected org.springframework.data.gemfire.function.execution.FunctionExecutionMethodMetadata<org.springframework.data.gemfire.function.execution.MethodMetadata> getFunctionExecutionMethodMetadata()
@NonNull protected GemfireFunctionOperations getGemfireFunctionOperations()
@Nullable public Object invoke(@NonNull MethodInvocation invocation)
invoke
in interface MethodInterceptor
@Nullable protected Object invokeFunction(@NonNull Method method, @NonNull Object[] args)
protected boolean isFunctionExecutedOnSingleServerOrSingleMember(@NonNull Method method)
protected Object resolveResult(MethodInvocation invocation, Object result)
protected boolean isInstanceOfFunctionReturnType(MethodInvocation invocation, Object value)
protected boolean isNotInstanceOfFunctionReturnType(MethodInvocation invocation, Object value)
protected boolean isIterable(Object value)
public Object getObject() throws Exception
getObject
in interface FactoryBean<Object>
Exception
public Class<?> getObjectType()
getObjectType
in interface FactoryBean<Object>
protected void onInit()
Copyright © 2011–2021 Pivotal Software, Inc.. All rights reserved.