X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-binding-broker%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Fbinding%2Fcodegen%2FRuntimeCodeGenerator.java;h=fb6f6ca1013b506eacf1f3b32ebdaf5d8aaf50ef;hp=0d78109a69c50e12a6d6c226465511f47f7b6b45;hb=2e29ba0089e109c71af6fae1a6811255f9845049;hpb=a251833f27fd00040904e2df316cd707c8129d1e
diff --git a/opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/codegen/RuntimeCodeGenerator.java b/opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/codegen/RuntimeCodeGenerator.java
index 0d78109a69..fb6f6ca101 100644
--- a/opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/codegen/RuntimeCodeGenerator.java
+++ b/opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/codegen/RuntimeCodeGenerator.java
@@ -7,8 +7,8 @@
*/
package org.opendaylight.controller.sal.binding.codegen;
-import org.opendaylight.controller.sal.binding.spi.DelegateProxy;
-import org.opendaylight.controller.sal.binding.spi.RpcRouter;
+import org.opendaylight.controller.sal.binding.api.rpc.RpcRouter;
+import org.opendaylight.controller.sal.binding.spi.NotificationInvokerFactory;
import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
import org.opendaylight.yangtools.yang.binding.RpcService;
import org.opendaylight.yangtools.yang.binding.annotations.RoutingContext;
@@ -18,7 +18,7 @@ public interface RuntimeCodeGenerator {
/**
* Returns an instance of provided RpcService type which delegates all calls
* to the delegate.
- *
+ *
*
* Returned instance:
*
@@ -36,53 +36,57 @@ public interface RuntimeCodeGenerator {
* all calls are delegated.
* - {@link DelegateProxy#setDelegate(Object)} - sets the delegate for
* particular instance
- *
+ *
*
- *
+ *
* @param serviceType
* - Subclass of RpcService for which direct proxy is to be
* generated.
* @return Instance of RpcService of provided serviceType which implements
* and {@link DelegateProxy}
* @throws IllegalArgumentException
- *
+ *
*/
T getDirectProxyFor(Class serviceType) throws IllegalArgumentException;
/**
* Returns an instance of provided RpcService type which routes all calls to
* other instances selected on particular input field.
- *
+ *
*
* Returned instance:
- *
- Implements:
- *
- {@link DelegateProxy}
- *
- {@link RpcRouter}
- *
- * -
- * routes all invocations of methods, which are defined in RpcService
- * subtype based on method arguments and routing information defined in the
- * RpcRoutingTables for this instance
- * {@link RpcRouter#getRoutingTable(Class)}.
- *
- * -
- * Implementation uses
- * {@link RpcRouter#getService(Class, InstanceIdentifier)} method to
- * retrieve particular instance to which call will be routed.
- *
-
- * Instance of {@link InstanceIdentifier} is determined by first argument of
- * method and is retrieved via method which is annotated with
- * {@link RoutingContext}. Class representing Routing Context Identifier is
- * retrieved by {@link RoutingContext}.
- *
- If first argument is not defined / {@link RoutingContext} annotation
- * is not present on any field invocation will be delegated to default
- * service {@link RpcRouter#getDefaultService()}.
+ *
+ * - Implements:
+ *
+ * - {@link DelegateProxy}
+ *
- {@link RpcRouter}
+ *
+ * -
+ * routes all invocations of methods, which are defined in RpcService
+ * subtype based on method arguments and routing information defined in the
+ * RpcRoutingTables for this instance
+ * {@link RpcRouter#getRoutingTable(Class)}.
+ *
+ * -
+ * Implementation uses
+ * {@link RpcRouter#getService(Class, InstanceIdentifier)} method to
+ * retrieve particular instance to which call will be routed.
+ *
-
+ * Instance of {@link InstanceIdentifier} is determined by first argument of
+ * method and is retrieved via method which is annotated with
+ * {@link RoutingContext}. Class representing Routing Context Identifier is
+ * retrieved by {@link RoutingContext}.
+ *
- If first argument is not defined / {@link RoutingContext} annotation
+ * is not present on any field invocation will be delegated to default
+ * service {@link RpcRouter#getDefaultService()}.
*
- *
+ *
* @param serviceType
* - Subclass of RpcService for which Router is to be generated.
* @return Instance of RpcService of provided serviceType which implements
* also {@link RpcRouter} and {@link DelegateProxy}
*/
- T getRouterFor(Class serviceType) throws IllegalArgumentException;
+ RpcRouter getRouterFor(Class serviceType,String name) throws IllegalArgumentException;
+
+ NotificationInvokerFactory getInvokerFactory();
}