Update sal-distributed-datastore tests a bit
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / cluster / datastore / config / Configuration.java
index b6122b3d29f4f07eada831feaa5765c3a073047f..4325c7f268a0fb7c6cc0d8edf0d983648d0d19d7 100644 (file)
@@ -5,13 +5,13 @@
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
-
 package org.opendaylight.controller.cluster.datastore.config;
 
 import java.util.Collection;
 import java.util.Set;
-import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.opendaylight.controller.cluster.access.concepts.MemberName;
 import org.opendaylight.controller.cluster.datastore.shardstrategy.ShardStrategy;
 
 public interface Configuration {
@@ -19,27 +19,27 @@ public interface Configuration {
     /**
      * Returns all the shard names that belong on the member by the given name.
      */
-    @Nonnull Collection<String> getMemberShardNames(@Nonnull String memberName);
+    @NonNull Collection<String> getMemberShardNames(@NonNull MemberName memberName);
 
     /**
      * Returns the module name for the given namespace name or null if not found.
      */
-    @Nullable String getModuleNameFromNameSpace(@Nonnull String nameSpace);
+    @Nullable String getModuleNameFromNameSpace(@NonNull String nameSpace);
 
     /**
      * Returns the first shard name corresponding to the given module name or null if none is configured.
      */
-    @Nullable String getShardNameForModule(@Nonnull String moduleName);
+    @Nullable String getShardNameForModule(@NonNull String moduleName);
 
     /**
      * Returns the member replicas for the given shard name.
      */
-    @Nonnull Collection<String> getMembersFromShardName(@Nonnull String shardName);
+    @NonNull Collection<MemberName> getMembersFromShardName(@NonNull String shardName);
 
     /**
      * Returns the ShardStrategy for the given module name or null if the module is not found.
      */
-    @Nullable ShardStrategy getStrategyForModule(@Nonnull String moduleName);
+    @Nullable ShardStrategy getStrategyForModule(@NonNull String moduleName);
 
     /**
      * Returns all the configured shard names.
@@ -49,12 +49,12 @@ public interface Configuration {
     /**
      * Adds a new configuration for a module and shard.
      */
-    void addModuleShardConfiguration(@Nonnull ModuleShardConfiguration config);
+    void addModuleShardConfiguration(@NonNull ModuleShardConfiguration config);
 
     /**
      * Returns a unique set of all member names configured for all shards.
      */
-    Collection<String> getUniqueMemberNamesForAllShards();
+    Collection<MemberName> getUniqueMemberNamesForAllShards();
 
     /*
      * Verifies if the given module shard in available in the cluster
@@ -62,12 +62,12 @@ public interface Configuration {
     boolean isShardConfigured(String shardName);
 
     /**
-     * Adds the given member as the new replica for the given shardName
+     * Adds the given member as the new replica for the given shardName.
      */
-    void addMemberReplicaForShard (String shardName, String memberName);
+    void addMemberReplicaForShard(String shardName, MemberName memberName);
 
     /**
-     * Removes the given member as a replica for the given shardName
+     * Removes the given member as a replica for the given shardName.
      */
-    void removeMemberReplicaForShard (String shardName, String memberName);
+    void removeMemberReplicaForShard(String shardName, MemberName memberName);
 }