use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstNxRegCaseBuilder in project netvirt by opendaylight.
the class OpenFlow13Utils method createActionNxMoveNsc4ToReg6Register.
public static Action createActionNxMoveNsc4ToReg6Register(int order) {
ActionBuilder ab = createActionBuilder(order);
ab.setAction(nxMoveRegAction(new SrcNxNshc4CaseBuilder().setNxNshc4Dst(Boolean.TRUE).build(), new DstNxRegCaseBuilder().setNxReg(NxmNxReg6.class).build(), 31, false));
return ab.build();
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstNxRegCaseBuilder in project openflowplugin by opendaylight.
the class Test method createNxActionBld.
private static ActionBuilder createNxActionBld(int actionKeyVal) {
// vendor part
DstNxRegCaseBuilder nxRegCaseBld = new DstNxRegCaseBuilder().setNxReg(NxmNxReg0.class);
DstBuilder dstBld = new DstBuilder().setDstChoice(nxRegCaseBld.build()).setStart(0).setEnd(5);
NxRegLoadBuilder nxRegLoadBuilder = new NxRegLoadBuilder();
nxRegLoadBuilder.setDst(dstBld.build());
nxRegLoadBuilder.setValue(BigInteger.valueOf(55L));
NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder topNxActionCaseBld = new NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder();
topNxActionCaseBld.setNxRegLoad(nxRegLoadBuilder.build());
// base part
ActionBuilder abExt = new ActionBuilder();
abExt.setKey(new ActionKey(actionKeyVal));
abExt.setAction(topNxActionCaseBld.build());
return abExt;
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstNxRegCaseBuilder in project genius by opendaylight.
the class MDSALUtil method createSetReg6Action.
/**
* Create action to set REG6 to the given value.
*
* @param actionKey the action key.
* @param startOffSet the start offset.
* @param endOffSet the end offset.
* @param value the value.
* @return the action.
*/
public static Action createSetReg6Action(int actionKey, int startOffSet, int endOffSet, long value) {
NxRegLoadBuilder nxRegLoadBuilder = new NxRegLoadBuilder();
Dst dst = new DstBuilder().setDstChoice(new DstNxRegCaseBuilder().setNxReg(NxmNxReg6.class).build()).setStart(startOffSet).setEnd(endOffSet).build();
nxRegLoadBuilder.setDst(dst);
nxRegLoadBuilder.setValue(new BigInteger(Long.toString(value)));
ActionBuilder ab = new ActionBuilder();
ab.setAction(new NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build());
ab.setKey(new ActionKey(actionKey));
return ab.build();
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstNxRegCaseBuilder in project genius by opendaylight.
the class ActionRegLoad method buildAction.
@Override
public Action buildAction(int newActionKey) {
Dst dst = new DstBuilder().setDstChoice(new DstNxRegCaseBuilder().setNxReg(register).build()).setStart(start).setEnd(end).build();
NxRegLoadBuilder nxRegLoadBuilder = new NxRegLoadBuilder().setDst(dst).setValue(BigInteger.valueOf(load));
return new ActionBuilder().setAction(new NxActionRegLoadNodesNodeTableFlowApplyActionsCaseBuilder().setNxRegLoad(nxRegLoadBuilder.build()).build()).setKey(new ActionKey(newActionKey)).build();
}
Aggregations