Merge "toaster-it: add missing version for maven-paxexam-plugin"
[controller.git] / opendaylight / sal / api / src / main / java / org / opendaylight / controller / sal / core / NodeTable.java
index 22c379614dbd0657d0d97e556a06f48a25b91309..7b7f1ccaeaf22f29dc4fa2a9c35b75854086b46f 100644 (file)
@@ -118,6 +118,7 @@ public class NodeTable implements Serializable {
     /**
      * Private constructor used for JAXB mapping
      */
+    @SuppressWarnings("unused")
     private NodeTable() {
         this.nodeTableIDString = null;
         this.nodeTableID = null;
@@ -205,9 +206,9 @@ public class NodeTable implements Serializable {
     /**
      * @return the nodeTableIDString
      */
-    @XmlAttribute(name = "id")
+    @XmlElement(name = "id")
     public String getNodeTableIDString() {
-        return this.nodeTableIDString.toString();
+        return this.nodeTableIDString != null? this.nodeTableIDString : nodeTableID.toString();
     }
 
     /**