Replace LOGGER by LOG
[controller.git] / opendaylight / config / yang-jmx-generator-plugin / src / main / java / org / opendaylight / controller / config / yangjmxgenerator / plugin / gofactory / AbsModuleGeneratedObjectFactory.java
index 92a0eec5866877834f4fef563e9d3a3e06acc3aa..0deae078f3a61871aefa640e6ff7bc28075b5a10 100644 (file)
@@ -149,8 +149,8 @@ public class AbsModuleGeneratedObjectFactory {
         return "\n"+
             "@Override\n"+
             "public boolean equals(Object o) {\n"+
-                "if (this == o) return true;\n"+
-                "if (o == null || getClass() != o.getClass()) return false;\n"+
+                "if (this == o) { return true; }\n"+
+                "if (o == null || getClass() != o.getClass()) { return false; }\n"+
                 format("%s that = (%1$s) o;\n", abstractFQN.getTypeName())+
                 "return identifier.equals(that.identifier);\n"+
             "}\n"+
@@ -182,7 +182,7 @@ public class AbsModuleGeneratedObjectFactory {
 
         for (ModuleField moduleField : moduleFields) {
             result += format(
-                "if (java.util.Objects.deepEquals(%s, other.%1$s) == false) {\n"+
+                "if (!java.util.Objects.deepEquals(%s, other.%1$s)) {\n"+
                     "return false;\n"+
                 "}\n", moduleField.getName());
 
@@ -367,7 +367,7 @@ public class AbsModuleGeneratedObjectFactory {
     }
 
     private static String getLoggerDefinition(FullyQualifiedName fqn) {
-        return format("private static final %s LOGGER = %s.getLogger(%s.class);",
+        return format("private static final %s LOG = %s.getLogger(%s.class);",
                 Logger.class.getCanonicalName(), LoggerFactory.class.getCanonicalName(), fqn);
     }
 
@@ -401,6 +401,6 @@ public class AbsModuleGeneratedObjectFactory {
     }
 
     public String getGetLogger() {
-        return new MethodDefinition(Logger.class.getCanonicalName(), "getLogger", Collections.<Field>emptyList(), "return LOGGER;").toString();
+        return new MethodDefinition(Logger.class.getCanonicalName(), "getLogger", Collections.<Field>emptyList(), "return LOG;").toString();
     }
 }