Expand Identifiable documentation 30/52030/4
authorRobert Varga <rovarga@cisco.com>
Sat, 18 Feb 2017 11:28:14 +0000 (12:28 +0100)
committerRobert Varga <nite@hq.sk>
Thu, 23 Feb 2017 10:13:27 +0000 (10:13 +0000)
Make sure the identifier returned cannot be null, as it does not make
sense.

Change-Id: I2d8c7a17487da66fe91f44a597d74abae82c10bd
Signed-off-by: Robert Varga <rovarga@cisco.com>
common/concepts/src/main/java/org/opendaylight/yangtools/concepts/Identifiable.java

index cf91864260f489409fd01881b264b62a3e8d4874..99d6b77197fc81b5ef13850e046b761dea776994 100644 (file)
@@ -7,7 +7,13 @@
  */
 package org.opendaylight.yangtools.concepts;
 
-public interface Identifiable<T> {
+import javax.annotation.Nonnull;
 
-    T getIdentifier();
+public interface Identifiable<T> {
+    /**
+     * Return this objects Identifier
+     *
+     * @return Object's identifier, must not be null.
+     */
+    @Nonnull T getIdentifier();
 }