Modernize mdsal-dom-{api,spi}
[mdsal.git] / dom / mdsal-dom-api / src / main / java / org / opendaylight / mdsal / dom / api / DOMActionInstance.java
index d16c6db73bbfd9be9f91ac435255c944d13d6f0e..5b2f170267f915bdc7db34ec51664316412308d6 100644 (file)
@@ -74,14 +74,8 @@ public final class DOMActionInstance implements Immutable {
 
     @Override
     public boolean equals(final @Nullable Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!(obj instanceof DOMActionInstance)) {
-            return false;
-        }
-        final DOMActionInstance other = (DOMActionInstance) obj;
-        return getType().equals(other.type) && dataTrees.equals(other.dataTrees);
+        return this == obj || obj instanceof DOMActionInstance other && getType().equals(other.type)
+            && dataTrees.equals(other.dataTrees);
     }
 
     @Override