diff options
Diffstat (limited to 'java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java')
-rw-r--r-- | java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java | 78 |
1 files changed, 17 insertions, 61 deletions
diff --git a/java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java b/java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java index 86c808c0fb..d6f8431d48 100644 --- a/java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java +++ b/java/sca/modules/core-spi/src/main/java/org/apache/tuscany/sca/runtime/RuntimeEndpointReference.java @@ -20,70 +20,15 @@ package org.apache.tuscany.sca.runtime; import java.io.Serializable; -import java.lang.reflect.InvocationTargetException; -import java.util.List; import org.apache.tuscany.sca.assembly.EndpointReference; -import org.apache.tuscany.sca.interfacedef.Operation; -import org.apache.tuscany.sca.invocation.InvocationChain; -import org.apache.tuscany.sca.invocation.Message; -import org.apache.tuscany.sca.provider.PolicyProvider; +import org.apache.tuscany.sca.interfacedef.InterfaceContract; import org.apache.tuscany.sca.provider.ReferenceBindingProvider; /** * The runtime representation of an endpoint reference */ -public interface RuntimeEndpointReference extends EndpointReference, Serializable { - /** - * Returns the invocation chains for service operations associated with the - * wire - * - * @return the invocation chains for service operations associated with the - * wire - */ - List<InvocationChain> getInvocationChains(); - - /** - * Lookup the invocation chain by operation - * @param operation The operation - * @return The invocation chain for the given operation - */ - InvocationChain getInvocationChain(Operation operation); - - /** - * Get the invocation chain for the binding-specific handling - * @return The binding invocation chain - */ - InvocationChain getBindingInvocationChain(); - - /** - * This invoke method assumes that the binding invocation chain is in force - * and that there will be an operation selector element there to - * determine which operation to call - * @param msg The message - * @return The result - * @throws InvocationTargetException - */ - Object invoke(Message msg) throws InvocationTargetException; - - /** - * Invoke an operation with given arguments - * @param operation The operation - * @param args The arguments - * @return The result - * @throws InvocationTargetException - */ - Object invoke(Operation operation, Object[] args) throws InvocationTargetException; - - /** - * Invoke an operation with a context message - * @param operation The operation - * @param msg The message - * @return The result - * @throws InvocationTargetException - */ - Object invoke(Operation operation, Message msg) throws InvocationTargetException; - +public interface RuntimeEndpointReference extends EndpointReference, Invocable, Serializable { /** * Set the reference binding provider for the endpoint reference * @param provider The binding provider @@ -95,10 +40,21 @@ public interface RuntimeEndpointReference extends EndpointReference, Serializabl * @return The binding provider */ ReferenceBindingProvider getBindingProvider(); - /** - * Get the list of policy providers for the endpoint reference - * @return A list of policy providers for the endpoint reference + * Get the interface contract for the binding. This represents the data types that the binding + * protocol stack can process. + * @return The binding interface contract */ - List<PolicyProvider> getPolicyProviders(); + InterfaceContract getBindingInterfaceContract(); + + /** + * Get the interface contract of the reference of the source component type, i.e., the + * componentType.reference.interfaceContract. This represents the data types that the + * implementation code uses to make the outbound call. + * @return The source component type reference interface contract + */ + InterfaceContract getReferenceInterfaceContract(); + boolean isOutOfDate(); + void rebuild(); + } |