/** * @see org.apache.tuscany.sca.core.invocation.ProxyFactory#isProxyClass(java.lang.Class) */ public boolean isProxyClass(Class<?> clazz) { ProxyFactory interfaceFactory = proxyFactories.getInterfaceProxyFactory(); ProxyFactory classFactory = proxyFactories.getClassProxyFactory(); return interfaceFactory.isProxyClass(clazz) || (classFactory != null && classFactory.isProxyClass(clazz)); }
@Override public void invokeAsyncRequest(Message msg) throws Throwable { invokeAsync(msg); } // end method invokeAsyncRequest }
/** * Constructor which creates an AsyncFaultWrapper which wraps the supplied Throwable * @param e - a Throwable which is wrapped by this AsyncFaultWrapper */ public AsyncFaultWrapper( Throwable e ) { super(); storeFault( e ); }
/** * @see org.apache.tuscany.sca.core.invocation.ProxyFactory#createProxy(java.lang.Class, * org.apache.tuscany.sca.runtime.Invocable) */ public <T> T createProxy(Class<T> interfaze, Invocable wire) throws ProxyCreationException { ProxyFactory interfaceFactory = proxyFactories.getInterfaceProxyFactory(); ProxyFactory classFactory = proxyFactories.getClassProxyFactory(); if (interfaze.isInterface()) { return interfaceFactory.createProxy(interfaze, wire); } else { return classFactory.createProxy(interfaze, wire); } }
/** * @see org.apache.tuscany.sca.core.invocation.ProxyFactory#createCallbackProxy(java.lang.Class, * java.util.List) */ public <T> T createCallbackProxy(Class<T> interfaze, List<? extends Invocable> wires) throws ProxyCreationException { ProxyFactory interfaceFactory = proxyFactories.getInterfaceProxyFactory(); ProxyFactory classFactory = proxyFactories.getClassProxyFactory(); if (interfaze.isInterface()) { return interfaceFactory.createCallbackProxy(interfaze, wires); } else { return classFactory.createCallbackProxy(interfaze, wires); } }
protected B createProxy() throws Exception { return proxyFactory.createProxy(this); }
@SuppressWarnings("unchecked") public <B, R extends ServiceReference<B>> R cast(B target) throws IllegalArgumentException { return (R)proxyFactory.cast(target); }
public CallbackHandler(String callbackTargetURI, boolean cloneCallbackWire){ setCallbackTargetURI(callbackTargetURI); setCloneCallbackWire(cloneCallbackWire); }
public Object invoke(Operation operation, Object[] args) throws InvocationTargetException { return invoker.invoke(operation, args); }
@Override protected B createProxy() throws Exception { return proxyFactory.createCallbackProxy(this); }
public void invokeAsync(Message msg){ invoker.invokeBindingAsync(msg); } // end method invokeAsync(Message)
public CallbackHandler(String callbackTargetURI){ setCallbackTargetURI(callbackTargetURI); }
public <T> T createCallbackProxy(ServiceReference<T> callbackReference) throws ProxyCreationException { ProxyFactory interfaceFactory = proxyFactories.getInterfaceProxyFactory(); ProxyFactory classFactory = proxyFactories.getClassProxyFactory(); if (callbackReference.getBusinessInterface().isInterface()) { return interfaceFactory.createCallbackProxy(callbackReference); } else { return classFactory.createCallbackProxy(callbackReference); } }
@SuppressWarnings("unchecked") public <B, R extends ServiceReference<B>> R cast(B target) throws IllegalArgumentException { return (R)proxyFactory.cast(target); }
public Message invoke(Operation operation, Message msg) { return invoker.invoke(operation, msg); }
public void invokeAsync(Message msg){ invoker.invokeAsync(msg); }
public B getInstance() throws ObjectCreationException { return proxyFactory.createCallbackProxy(businessInterface, wires); }
public Message invoke(Operation operation, Message msg) { return invoker.invoke(operation, msg); }
public Message invoke(Message msg) { return invoker.invoke(msg); }
public Object invoke(Operation operation, Object[] args) throws InvocationTargetException { return invoker.invoke(operation, args); }