use of org.opendaylight.yang.gen.v1.urn.tech.pantheon.netconfdevice.network.topology.rpcs.rev180320.node.data.Node in project netvirt by opendaylight.
the class LocalUcastCmd method transform.
@Override
public LocalUcastMacs transform(InstanceIdentifier<Node> nodePath, LocalUcastMacs src) {
LocalUcastMacsBuilder ucmlBuilder = new LocalUcastMacsBuilder(src);
ucmlBuilder.setLocatorRef(HwvtepHAUtil.convertLocatorRef(src.getLocatorRef(), nodePath));
ucmlBuilder.setLogicalSwitchRef(HwvtepHAUtil.convertLogicalSwitchRef(src.getLogicalSwitchRef(), nodePath));
String srcTorNodeId = ((InstanceIdentifier<LogicalSwitches>) src.getLogicalSwitchRef().getValue()).firstKeyOf(Node.class).getNodeId().getValue();
SrcnodeAugmentation srcnodeAugmentation = new SrcnodeAugmentationBuilder().setSrcTorNodeid(srcTorNodeId).build();
ucmlBuilder.addAugmentation(srcnodeAugmentation);
ucmlBuilder.setMacEntryUuid(HwvtepHAUtil.getUUid(src.getMacEntryKey().getValue()));
LocalUcastMacsKey key = new LocalUcastMacsKey(ucmlBuilder.getLogicalSwitchRef(), ucmlBuilder.getMacEntryKey());
ucmlBuilder.withKey(key);
return ucmlBuilder.build();
}
use of org.opendaylight.yang.gen.v1.urn.tech.pantheon.netconfdevice.network.topology.rpcs.rev180320.node.data.Node in project netvirt by opendaylight.
the class RemoteMcastCmd method generateId.
@Override
public InstanceIdentifier<RemoteMcastMacs> generateId(InstanceIdentifier<Node> id, RemoteMcastMacs node) {
HwvtepLogicalSwitchRef lsRef = HwvtepHAUtil.convertLogicalSwitchRef(node.key().getLogicalSwitchRef(), id);
RemoteMcastMacsKey key = new RemoteMcastMacsKey(lsRef, node.getMacEntryKey());
return id.augmentation(HwvtepGlobalAugmentation.class).child(RemoteMcastMacs.class, key);
}
use of org.opendaylight.yang.gen.v1.urn.tech.pantheon.netconfdevice.network.topology.rpcs.rev180320.node.data.Node in project netvirt by opendaylight.
the class RemoteMcastCmd method transform.
@Override
public RemoteMcastMacs transform(InstanceIdentifier<Node> nodePath, RemoteMcastMacs src) {
RemoteMcastMacsBuilder ucmlBuilder = new RemoteMcastMacsBuilder(src);
List<LocatorSet> locatorSet = new ArrayList<>();
for (LocatorSet locator : src.nonnullLocatorSet()) {
locatorSet.add(new LocatorSetBuilder().setLocatorRef(HwvtepHAUtil.buildLocatorRef(nodePath, HwvtepHAUtil.getTepIpVal(locator.getLocatorRef()))).build());
}
ucmlBuilder.setLocatorSet(locatorSet);
ucmlBuilder.setLogicalSwitchRef(HwvtepHAUtil.convertLogicalSwitchRef(src.getLogicalSwitchRef(), nodePath));
ucmlBuilder.setMacEntryUuid(HwvtepHAUtil.getUUid(src.getMacEntryKey().getValue()));
RemoteMcastMacsKey key = new RemoteMcastMacsKey(ucmlBuilder.getLogicalSwitchRef(), ucmlBuilder.getMacEntryKey());
ucmlBuilder.withKey(key);
return ucmlBuilder.build();
}
use of org.opendaylight.yang.gen.v1.urn.tech.pantheon.netconfdevice.network.topology.rpcs.rev180320.node.data.Node in project netvirt by opendaylight.
the class RemoteUcastCmd method generateId.
@Override
public InstanceIdentifier<RemoteUcastMacs> generateId(InstanceIdentifier<Node> id, RemoteUcastMacs node) {
HwvtepLogicalSwitchRef lsRef = HwvtepHAUtil.convertLogicalSwitchRef(node.key().getLogicalSwitchRef(), id);
RemoteUcastMacsKey key = new RemoteUcastMacsKey(lsRef, node.getMacEntryKey());
return id.augmentation(HwvtepGlobalAugmentation.class).child(RemoteUcastMacs.class, key);
}
use of org.opendaylight.yang.gen.v1.urn.tech.pantheon.netconfdevice.network.topology.rpcs.rev180320.node.data.Node in project netvirt by opendaylight.
the class RemoteUcastCmd method transform.
@Override
public RemoteUcastMacs transform(InstanceIdentifier<Node> nodePath, RemoteUcastMacs src) {
RemoteUcastMacsBuilder ucmlBuilder = new RemoteUcastMacsBuilder(src);
ucmlBuilder.setLocatorRef(HwvtepHAUtil.convertLocatorRef(src.getLocatorRef(), nodePath));
ucmlBuilder.setLogicalSwitchRef(HwvtepHAUtil.convertLogicalSwitchRef(src.getLogicalSwitchRef(), nodePath));
ucmlBuilder.setMacEntryUuid(HwvtepHAUtil.getUUid(src.getMacEntryKey().getValue()));
RemoteUcastMacsKey key = new RemoteUcastMacsKey(ucmlBuilder.getLogicalSwitchRef(), ucmlBuilder.getMacEntryKey());
ucmlBuilder.withKey(key);
return ucmlBuilder.build();
}
Aggregations