Fix Types.getDefaultRestrictions() 60/97660/1
authorRobert Varga <robert.varga@pantheon.tech>
Tue, 28 Sep 2021 03:39:16 +0000 (05:39 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Tue, 28 Sep 2021 03:40:10 +0000 (05:40 +0200)
We have a warning about class visibility, fix it by using public
interface. Also mark the method for removal, as it does not seem
to be used.

Change-Id: I00556715ef3200dc2b46540a05c8e6c0fea0f55e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
binding/mdsal-binding-model-ri/src/main/java/org/opendaylight/mdsal/binding/model/ri/Types.java

index f043eae70023555e9cc02a715b4413a255f32b8e..186582d60b8fbd4707ef93302783acccc53c95ad 100644 (file)
@@ -305,7 +305,7 @@ public final class Types {
 
         @Override
         public Restrictions getRestrictions() {
-            return this.restrictions;
+            return restrictions;
         }
     }
 
@@ -329,7 +329,7 @@ public final class Types {
 
         @Override
         public Restrictions getRestrictions() {
-            return this.restrictions;
+            return restrictions;
         }
     }
 
@@ -365,12 +365,12 @@ public final class Types {
         @Override
         public Type[] getActualTypeArguments() {
 
-            return this.actualTypes;
+            return actualTypes;
         }
 
         @Override
         public Type getRawType() {
-            return this.rawType;
+            return rawType;
         }
     }
 
@@ -389,8 +389,8 @@ public final class Types {
         }
     }
 
-    public static <T extends Number & Comparable<T>> DefaultRestrictions<T> getDefaultRestrictions(final T min,
-            final T max) {
+    // FIXME: 9.0.0: remove this method
+    public static <T extends Number & Comparable<T>> Restrictions getDefaultRestrictions(final T min, final T max) {
         return new DefaultRestrictions<>(min, max);
     }