use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nodes.node.group.buckets.bucket.action.action.NxActionRegLoadNodesNodeGroupBucketsBucketActionsCaseBuilder in project genius by opendaylight.
the class ActionSetTunnelDestinationIp method buildAction.
@Override
public Action buildAction(int newActionKey) {
NxRegLoadBuilder nxRegLoadBuilder = new NxRegLoadBuilder();
Dst dst = new DstBuilder().setDstChoice(new DstNxTunIpv4DstCaseBuilder().setNxTunIpv4Dst(Boolean.TRUE).build()).setStart(0).setEnd(31).build();
nxRegLoadBuilder.setDst(dst);
nxRegLoadBuilder.setValue(destIp);
ActionBuilder ab = new ActionBuilder();
if (groupBucket) {
ab.setAction(new NxActionRegLoadNodesNodeGroupBucketsBucketActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build());
} else {
ab.setAction(new NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build());
}
ab.setKey(new ActionKey(newActionKey));
return ab.build();
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nodes.node.group.buckets.bucket.action.action.NxActionRegLoadNodesNodeGroupBucketsBucketActionsCaseBuilder in project genius by opendaylight.
the class ActionSetTunnelSourceIp method buildAction.
@Override
public Action buildAction(int newActionKey) {
NxRegLoadBuilder nxRegLoadBuilder = new NxRegLoadBuilder();
Dst dst = new DstBuilder().setDstChoice(new DstNxTunIpv4SrcCaseBuilder().setNxTunIpv4Src(Boolean.TRUE).build()).setStart(0).setEnd(31).build();
nxRegLoadBuilder.setDst(dst);
nxRegLoadBuilder.setValue(sourceIp);
ActionBuilder ab = new ActionBuilder();
if (groupBucket) {
ab.setAction(new NxActionRegLoadNodesNodeGroupBucketsBucketActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build());
} else {
ab.setAction(new NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build());
}
ab.setKey(new ActionKey(newActionKey));
return ab.build();
}
Aggregations