|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rioproject.associations.AssociationProxySupport<T>
public class AssociationProxySupport<T>
Provides support for an AssociationProxy
| Nested Class Summary | |
|---|---|
class |
AssociationProxySupport.Interceptor
|
class |
AssociationProxySupport.LocalCallbackFilter
|
class |
AssociationProxySupport.LocalInterceptor
|
| Constructor Summary | |
|---|---|
AssociationProxySupport()
|
|
| Method Summary | |
|---|---|
void |
broken(Association<T> association,
T service)
Notification that an Association is broken |
void |
changed(Association<T> association,
T service)
Notification that an Association has changed |
void |
discovered(Association<T> association,
T service)
Notification that an Association has been discovered |
Object |
doInvokeService(Association<T> a,
Method method,
Object[] args)
|
Association |
getAssociation()
Get the association |
net.sf.cglib.proxy.CallbackFilter |
getCallbackFilter(Association<T> association)
Create a CallbackFilter |
net.sf.cglib.proxy.Callback[] |
getCallbacks(Association<T> association)
Create an array of Callback |
net.sf.cglib.proxy.Dispatcher |
getDispatcher(Association<T> association)
Create a Dispatcher |
long |
getInvocationCount()
Get the number of times the associated service(s) were invoked using this proxy |
InvocationHandler |
getInvocationHandler(Association<T> association)
Create an InvocationHandler |
ServiceSelectionStrategy<T> |
getServiceSelectionStrategy()
Get the ServiceSelectionStrategy |
Class |
getSuperClass()
Get the super-class when creating a concrete CGLIB proxy |
protected boolean |
isProxyMethod(Method method)
Ceck if the methos is found in the generated proxy |
void |
setProxyInterfaces(Class[] classes)
Set the classes the proxy will support |
void |
setServiceSelectionStrategy(ServiceSelectionStrategy<T> strategy)
Set the strategy for selecting services |
void |
terminate()
Clean up any resources allocated |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AssociationProxySupport()
| Method Detail |
|---|
public InvocationHandler getInvocationHandler(Association<T> association)
getInvocationHandler in interface AssociationProxy<T>association - The Association to use
AssociationProxySupport.AssociationInvocationHandler
instancepublic net.sf.cglib.proxy.Callback[] getCallbacks(Association<T> association)
Callback
getCallbacks in interface AssociationProxy<T>association - The Association to use
Callback for use with a
generated CGLIB proxy. This method returns a
AssociationProxySupport.LocalInterceptor as
the first Callback, followed by the
AssociationProxySupport.Interceptor class.
This method can be overriden to return a different array of
Callback instances if required.public net.sf.cglib.proxy.CallbackFilter getCallbackFilter(Association<T> association)
CallbackFilter
getCallbackFilter in interface AssociationProxy<T>association - The Association to use
CallbackFilter for use
with a generated CGLIB proxy. This method returns a
AssociationProxySupport.LocalCallbackFilter.
This method can be overriden to return a different
CallbackFilter if required.public net.sf.cglib.proxy.Dispatcher getDispatcher(Association<T> association)
Dispatcher
getDispatcher in interface AssociationProxy<T>association - The Association to use
Dispatcher for use with a generated
CGLIB proxy. This method returna a null. If the underlying proxy
requires a Dispatcher, this method should be overriden.public Association getAssociation()
AssociationProxy
getAssociation in interface AssociationProxy<T>public ServiceSelectionStrategy<T> getServiceSelectionStrategy()
ServiceSelectionStrategy
getServiceSelectionStrategy in interface AssociationProxy<T>public void setServiceSelectionStrategy(ServiceSelectionStrategy<T> strategy)
setServiceSelectionStrategy in interface AssociationProxy<T>strategy - The ServiceSelectionStrategy. Must not be null.
public void discovered(Association<T> association,
T service)
discovered in interface AssociationListener<T>association - The Associationservice - The associated service that has been discovered
public void changed(Association<T> association,
T service)
changed in interface AssociationListener<T>association - The Associationservice - The service that was removed, changing the endpoint
public void broken(Association<T> association,
T service)
broken in interface AssociationListener<T>association - The Association.service - The service that was removed, causing the Association to
be brokenpublic void terminate()
terminate in interface AssociationProxy<T>
public Object doInvokeService(Association<T> a,
Method method,
Object[] args)
throws Throwable
Throwableprotected boolean isProxyMethod(Method method)
method - The Method to check
public Class getSuperClass()
getSuperClass in interface AssociationProxy<T>public void setProxyInterfaces(Class[] classes)
AssociationProxy
setProxyInterfaces in interface AssociationProxy<T>classes - Array of interface classespublic long getInvocationCount()
AssociationProxy
getInvocationCount in interface AssociationProxy<T>
|
Copyright © Rio Project. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||