Modify config code generator to write JmxAttribute as static fields. 95/6595/1
authorTomas Olvecky <tolvecky@cisco.com>
Tue, 29 Apr 2014 12:32:51 +0000 (14:32 +0200)
committerTomas Olvecky <tolvecky@cisco.com>
Tue, 29 Apr 2014 12:32:51 +0000 (14:32 +0200)
Make JmxAttribute fields static so that name of the attribute can be
referenced and used to read from JMX.

Change-Id: Ibf2afbdfd8ae78e6ca46025671128bc7256f78d9
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
opendaylight/config/yang-jmx-generator-plugin/src/main/java/org/opendaylight/controller/config/yangjmxgenerator/plugin/ftl/model/ModuleFieldSerializer.java

index c0e3bc1ad84d6ab85b2010149b0286a01e440529..6211efe417973ee0f8faf637669e4f824a1df7f3 100644 (file)
@@ -16,7 +16,7 @@ public class ModuleFieldSerializer {
     public static String toString(ModuleField moduleField) {
         StringBuilder builder = new StringBuilder();
         builder.append("    ");
-        builder.append("protected final "
+        builder.append("public static final "
                 + JmxAttribute.class.getCanonicalName() + " "
                 + moduleField.getName() + "JmxAttribute = new "
                 + JmxAttribute.class.getCanonicalName() + "(\""