Revision should be Immutable 87/81587/1
authorRobert Varga <robert.varga@pantheon.tech>
Thu, 11 Apr 2019 19:42:21 +0000 (21:42 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Thu, 11 Apr 2019 22:44:37 +0000 (00:44 +0200)
This class has only a single member, which is immutable and is final,
which means it is Immutable. Reflect that in the class hierarchy.

Change-Id: I1cc8866e5d4b3344361581bf0037971855bd2f5d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 309ead000a3fe60ce86d86c8391d6e0c2e3e7720)

yang/yang-common/src/main/java/org/opendaylight/yangtools/yang/common/Revision.java

index d0b4233400ce26d7a02e8b4091c5015bb7f9d0df..8faaf1587ae8ccd70f33033bc8dc5f977663f35e 100644 (file)
@@ -21,6 +21,7 @@ import java.util.regex.Pattern;
 import javax.annotation.Nonnull;
 import javax.annotation.Nullable;
 import javax.annotation.RegEx;
+import org.opendaylight.yangtools.concepts.Immutable;
 
 /**
  * Dedicated object identifying a YANG module revision.
@@ -38,7 +39,7 @@ import javax.annotation.RegEx;
  *
  * @author Robert Varga
  */
-public final class Revision implements Comparable<Revision>, Serializable {
+public final class Revision implements Comparable<Revision>, Immutable, Serializable {
     // Note: since we are using writeReplace() this version is not significant.
     private static final long serialVersionUID = 1L;