summaryrefslogtreecommitdiffstats
path: root/infra/bgp-translate-api/src/main/java/io/fd
diff options
context:
space:
mode:
authorMarek Gradzki <mgradzki@cisco.com>2018-06-27 21:03:03 +0200
committerMarek Gradzki <mgradzki@cisco.com>2018-06-27 21:07:35 +0200
commitf601696f8e6456363a42fb9c6dbe703c4bf98dd7 (patch)
treec4294ec168aa5156f67fa7c89665d4d04818587a /infra/bgp-translate-api/src/main/java/io/fd
parent9410a994afc24692b8e9e3bbb05bbe80b113cc5b (diff)
bgp: mark parameters of RouteWriter @NonNull
The RouteWriter interface is used by LocRibChangeListener, which never passes null parameters. Change-Id: I33a775de6c67d24bc271c0af21c9634c661e85e9 Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Diffstat (limited to 'infra/bgp-translate-api/src/main/java/io/fd')
-rw-r--r--infra/bgp-translate-api/src/main/java/io/fd/honeycomb/translate/bgp/RouteWriter.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/infra/bgp-translate-api/src/main/java/io/fd/honeycomb/translate/bgp/RouteWriter.java b/infra/bgp-translate-api/src/main/java/io/fd/honeycomb/translate/bgp/RouteWriter.java
index a88d149ad..5f2b11b8c 100644
--- a/infra/bgp-translate-api/src/main/java/io/fd/honeycomb/translate/bgp/RouteWriter.java
+++ b/infra/bgp-translate-api/src/main/java/io/fd/honeycomb/translate/bgp/RouteWriter.java
@@ -20,7 +20,6 @@ import com.google.common.annotations.Beta;
import io.fd.honeycomb.translate.SubtreeManager;
import io.fd.honeycomb.translate.write.WriteFailedException;
import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.rib.rev171207.Route;
import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
@@ -40,7 +39,7 @@ public interface RouteWriter<R extends Route> extends SubtreeManager<R> {
* @throws WriteFailedException.CreateFailedException if create was unsuccessful
*/
void create(@Nonnull final InstanceIdentifier<R> id,
- @Nullable final R dataAfter) throws WriteFailedException.CreateFailedException;
+ @Nonnull final R dataAfter) throws WriteFailedException.CreateFailedException;
/**
* Handles delete operation.
@@ -49,7 +48,7 @@ public interface RouteWriter<R extends Route> extends SubtreeManager<R> {
* @throws WriteFailedException.DeleteFailedException if delete was unsuccessful
*/
void delete(@Nonnull final InstanceIdentifier<R> id,
- @Nullable final R dataBefore) throws WriteFailedException.DeleteFailedException;
+ @Nonnull final R dataBefore) throws WriteFailedException.DeleteFailedException;
/**
* Handles update operation.
@@ -59,6 +58,6 @@ public interface RouteWriter<R extends Route> extends SubtreeManager<R> {
* @throws WriteFailedException.UpdateFailedException if update was unsuccessful
*/
void update(@Nonnull final InstanceIdentifier<R> id,
- @Nullable final R dataBefore,
- @Nullable final R dataAfter) throws WriteFailedException.UpdateFailedException;
+ @Nonnull final R dataBefore,
+ @Nonnull final R dataAfter) throws WriteFailedException.UpdateFailedException;
}