BUG-272: fix sal-binding-broker 65/7865/1
authorRobert Varga <rovarga@cisco.com>
Tue, 10 Jun 2014 11:35:46 +0000 (13:35 +0200)
committerRobert Varga <rovarga@cisco.com>
Tue, 10 Jun 2014 11:37:30 +0000 (13:37 +0200)
Fixes various small offenses in sal-binding-broker

Change-Id: I621fa3a430e869ecaade06fb2bf189d692d90e85
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/codegen/RuntimeCodeGenerator.java
opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/impl/connect/dom/BindingIndependentConnector.java
opendaylight/md-sal/sal-binding-broker/src/main/java/org/opendaylight/controller/sal/binding/impl/util/BindingAwareDataReaderRouter.java

index fb6f6ca1013b506eacf1f3b32ebdaf5d8aaf50ef..9b7b8e28c90657aedc2f53c8c17d1697a0cd6e62 100644 (file)
@@ -9,9 +9,7 @@ package org.opendaylight.controller.sal.binding.codegen;
 
 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;
 
 public interface RuntimeCodeGenerator {
 
@@ -23,18 +21,18 @@ public interface RuntimeCodeGenerator {
      * Returned instance:
      * <ul>
      * <li>implements provided subclass of RpcService type and
-     * {@link DelegateProxy} interface.
+     * {@link org.opendaylight.controller.sal.binding.spi.DelegateProxy} interface.
      * <li>
      * <p>
      * delegates all invocations of methods, which are defined in RpcService
      * subtype to delegate which is defined by
-     * {@link DelegateProxy#setDelegate(Object)}.
+     * {@link org.opendaylight.controller.sal.binding.spi.DelegateProxy#setDelegate(Object)}.
      * <p>
      * If delegate is not defined (<code>getDelegate() == null</code>)
      * implementation throws {@link IllegalStateException}
-     * <li>{@link DelegateProxy#getDelegate()} - returns the delegate to which
+     * <li>{@link org.opendaylight.controller.sal.binding.spi.DelegateProxy#getDelegate()} - returns the delegate to which
      * all calls are delegated.
-     * <li>{@link DelegateProxy#setDelegate(Object)} - sets the delegate for
+     * <li>{@link org.opendaylight.controller.sal.binding.spi.DelegateProxy#setDelegate(Object)} - sets the delegate for
      * particular instance
      *
      * </ul>
@@ -43,7 +41,7 @@ public interface RuntimeCodeGenerator {
      *            - Subclass of RpcService for which direct proxy is to be
      *            generated.
      * @return Instance of RpcService of provided serviceType which implements
-     *         and {@link DelegateProxy}
+     *         and {@link org.opendaylight.controller.sal.binding.spi.DelegateProxy}
      * @throws IllegalArgumentException
      *
      */
@@ -58,7 +56,7 @@ public interface RuntimeCodeGenerator {
      * <ul>
      * <li>Implements:
      * <ul>
-     * <li>{@link DelegateProxy}
+     * <li>{@link org.opendaylight.controller.sal.binding.spi.DelegateProxy}
      * <li>{@link RpcRouter}
      * </ul>
      * <li>
@@ -69,14 +67,15 @@ public interface RuntimeCodeGenerator {
      * <ul>
      * <li>
      * Implementation uses
-     * {@link RpcRouter#getService(Class, InstanceIdentifier)} method to
+     * {@link RpcRouter#getService(Class, org.opendaylight.yangtools.yang.binding.InstanceIdentifier)} method to
      * retrieve particular instance to which call will be routed.
      * <li>
-     * Instance of {@link InstanceIdentifier} is determined by first argument of
+     * Instance of {@link org.opendaylight.yangtools.yang.binding.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}.
-     * <li>If first argument is not defined / {@link RoutingContext} annotation
+     * {@link org.opendaylight.yangtools.yang.binding.annotations.RoutingContext}.
+     * Class representing Routing Context Identifier is retrieved by a
+     * {@link org.opendaylight.yangtools.yang.binding.annotations.RoutingContext}.
+     * <li>If first argument is not defined / {@link org.opendaylight.yangtools.yang.binding.annotations.RoutingContext} annotation
      * is not present on any field invocation will be delegated to default
      * service {@link RpcRouter#getDefaultService()}.
      * </ul>
@@ -84,7 +83,7 @@ public interface RuntimeCodeGenerator {
      * @param serviceType
      *            - Subclass of RpcService for which Router is to be generated.
      * @return Instance of RpcService of provided serviceType which implements
-     *         also {@link RpcRouter}<T> and {@link DelegateProxy}
+     *         also {@link RpcRouter}<T> and {@link org.opendaylight.controller.sal.binding.spi.DelegateProxy}
      */
     <T extends RpcService> RpcRouter<T> getRouterFor(Class<T> serviceType,String name) throws IllegalArgumentException;
 
index 5bbebe6f1b00544021bb64d5cdf0ea4bf77c82a5..d2472669fa39def5ae4862fb86be2fea5fa7b067 100644 (file)
@@ -83,7 +83,6 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import com.google.common.base.Function;
-import com.google.common.base.Optional;
 import com.google.common.collect.FluentIterable;
 import com.google.common.collect.ImmutableSet;
 import com.google.common.collect.ImmutableSet.Builder;
index b0316635e2f03a981a6bc9ede0485e4df84023d9..97f74ff6f37c86f891e5a95ed0ae0c84dff9dc39 100644 (file)
@@ -7,14 +7,13 @@
  */
 package org.opendaylight.controller.sal.binding.impl.util;
 
-import java.util.Iterator;
 import org.opendaylight.controller.md.sal.common.impl.routing.AbstractDataReadRouter;
 import org.opendaylight.yangtools.yang.binding.DataObject;
 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
 
-@SuppressWarnings("all")
 public class BindingAwareDataReaderRouter extends AbstractDataReadRouter<InstanceIdentifier<? extends DataObject>,DataObject> {
-  protected DataObject merge(final InstanceIdentifier<? extends DataObject> path, final Iterable<DataObject> data) {
-    return data.iterator().next();
-  }
+    @Override
+    protected DataObject merge(final InstanceIdentifier<? extends DataObject> path, final Iterable<DataObject> data) {
+        return data.iterator().next();
+    }
 }