Search in sources :

Example 1 with NxMultipathBuilder

use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.multipath.grouping.NxMultipathBuilder in project openflowplugin by opendaylight.

the class MultipathConvertor method convert.

@Override
public org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action convert(final Action input, final ActionPath path) {
    NxActionMultipath action = ((ActionMultipath) input.getActionChoice()).getNxActionMultipath();
    DstBuilder dstBuilder = new DstBuilder();
    dstBuilder.setDstChoice(RegMoveConvertor.resolveDstValue(action.getDst()));
    dstBuilder.setStart(resolveStart(action.getOfsNbits()));
    dstBuilder.setEnd(resolveEnd(action.getOfsNbits()));
    NxMultipathBuilder builder = new NxMultipathBuilder();
    builder.setBasis(action.getBasis());
    builder.setAlgorithm(action.getAlgorithm());
    builder.setMaxLink(action.getMaxLink());
    builder.setArg(action.getArg());
    builder.setDst(dstBuilder.build());
    return resolveAction(builder.build(), path);
}
Also used : NxActionMultipath(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.ofj.nx.action.multipath.grouping.NxActionMultipath) DstBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.multipath.grouping.nx.multipath.DstBuilder) NxActionMultipath(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.ofj.nx.action.multipath.grouping.NxActionMultipath) ActionMultipath(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.action.container.action.choice.ActionMultipath) NxMultipathBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.multipath.grouping.NxMultipathBuilder)

Aggregations

ActionMultipath (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.action.container.action.choice.ActionMultipath)1 NxActionMultipath (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.ofj.nx.action.multipath.grouping.NxActionMultipath)1 NxMultipathBuilder (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.multipath.grouping.NxMultipathBuilder)1 DstBuilder (org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.action.rev140714.nx.action.multipath.grouping.nx.multipath.DstBuilder)1