- /**
- * Constructor to create DatalinkAddress property which contains the
- * controller MAC address and node MAC address. The property will be
- * attached to a {@link org.opendaylight.controller.sal.core.Node}.
- *
- * @param controllerMacAddress Data Link Address for the controller
- * @param nodeMacAddress Data Link Address for the node
- *
- * @return the constructed object
- */
- public MacAddress(byte[] controllerMacAddress, byte[] nodeMacAddress) {
- super(MacPropName);
-
- this.controllerMacAddress = controllerMacAddress;
- this.nodeMacAddress = nodeMacAddress;
+ /**
+ * Constructor to create DatalinkAddress property which contains the MAC
+ * address. The property will be attached to a
+ * {@link org.opendaylight.controller.sal.core.Node}.
+ *
+ *
+ * @param nodeMacAddress
+ * Data Link Address for the node in byte array format
+ *
+ * @return the constructed object
+ */
+ public MacAddress(byte[] nodeMacAddress) {
+ super(name);
+ this.address = HexEncode.bytesToHexStringFormat(nodeMacAddress);