Search in sources :

Example 1 with SrcOfEthSrcCase

use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.src.choice.grouping.src.choice.SrcOfEthSrcCase in project genius by opendaylight.

the class ActionMoveSourceDestinationEthTest method verifyAction.

private void verifyAction(Action action) {
    assertTrue(action.getAction() instanceof NxActionRegMoveNodesNodeTableFlowApplyActionsCase);
    NxActionRegMoveNodesNodeTableFlowApplyActionsCase actionCase = (NxActionRegMoveNodesNodeTableFlowApplyActionsCase) action.getAction();
    NxRegMove nxRegMove = actionCase.getNxRegMove();
    assertTrue(nxRegMove.getSrc().getSrcChoice() instanceof SrcOfEthSrcCase);
    SrcOfEthSrcCase srcChoice = (SrcOfEthSrcCase) nxRegMove.getSrc().getSrcChoice();
    assertTrue(srcChoice.isOfEthSrc());
    assertEquals(0, nxRegMove.getSrc().getStart().intValue());
    assertTrue(nxRegMove.getDst().getDstChoice() instanceof DstOfEthDstCase);
    DstOfEthDstCase dstChoice = (DstOfEthDstCase) nxRegMove.getDst().getDstChoice();
    assertTrue(dstChoice.isOfEthDst());
    assertEquals(0, nxRegMove.getDst().getStart().intValue());
    assertEquals(47, nxRegMove.getDst().getEnd().intValue());
}
Also used : DstOfEthDstCase(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstOfEthDstCase) NxRegMove(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.reg.move.grouping.NxRegMove) SrcOfEthSrcCase(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.src.choice.grouping.src.choice.SrcOfEthSrcCase) NxActionRegMoveNodesNodeTableFlowApplyActionsCase(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nodes.node.table.flow.instructions.instruction.instruction.apply.actions._case.apply.actions.action.action.NxActionRegMoveNodesNodeTableFlowApplyActionsCase)

Aggregations

DstOfEthDstCase (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.dst.choice.grouping.dst.choice.DstOfEthDstCase)1 NxActionRegMoveNodesNodeTableFlowApplyActionsCase (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nodes.node.table.flow.instructions.instruction.instruction.apply.actions._case.apply.actions.action.action.NxActionRegMoveNodesNodeTableFlowApplyActionsCase)1 NxRegMove (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.reg.move.grouping.NxRegMove)1 SrcOfEthSrcCase (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.src.choice.grouping.src.choice.SrcOfEthSrcCase)1