+ private void setLogicalSwitch(RemoteMcastMacsBuilder mMacRemoteBuilder, McastMacsRemote mMacRemote) {
+ LogicalSwitch lSwitch = null;
+ if (mMacRemote.getLogicalSwitchColumn() != null && mMacRemote.getLogicalSwitchColumn().getData() != null) {
+ UUID lsUUID = mMacRemote.getLogicalSwitchColumn().getData();
+ if (updatedLSRows.get(lsUUID) != null) {
+ lSwitch = updatedLSRows.get(lsUUID);
+ mMacRemoteBuilder.setLogicalSwitchRef(new HwvtepLogicalSwitchRef(lSwitch.getName()));
+ }
+ }
+ }
+
+ private void setIpAddress(RemoteMcastMacsBuilder mMacRemoteBuilder, McastMacsRemote mMacRemote) {
+ if(mMacRemote.getIpAddr() != null && !mMacRemote.getIpAddr().isEmpty()) {
+ mMacRemoteBuilder.setIpaddr(new IpAddress(mMacRemote.getIpAddr().toCharArray()));
+ }
+ }
+
+ private void setLocatorSet(RemoteMcastMacsBuilder mMacRemoteBuilder, McastMacsRemote mMacRemote) {
+ if (mMacRemote.getLocatorSetColumn() != null && mMacRemote.getLocatorSetColumn().getData() != null) {
+ UUID pLocSetUUID = mMacRemote.getLocatorSetColumn().getData();
+ if (updatedPLocSetRows.get(pLocSetUUID) != null) {
+ PhysicalLocatorSet plSet = updatedPLocSetRows.get(pLocSetUUID);
+ if (plSet.getLocatorsColumn() != null && plSet.getLocatorsColumn().getData() != null
+ && !plSet.getLocatorsColumn().getData().isEmpty()) {
+ List<LocatorSet> plsList = new ArrayList<>();
+ for (UUID pLocUUID : plSet.getLocatorsColumn().getData()) {
+ PhysicalLocator pLoc = updatedPLocRows.get(pLocUUID);
+ InstanceIdentifier<TerminationPoint> tpIid = HwvtepSouthboundMapper.createInstanceIdentifier(
+ getOvsdbConnectionInstance().getInstanceIdentifier(), pLoc);
+ plsList.add(new LocatorSetBuilder()
+ .setLocatorRef(new HwvtepPhysicalLocatorRef(tpIid)).build());
+ }
+ mMacRemoteBuilder.setLocatorSet(plsList);
+ }
+ }
+ }
+ }
+