use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.match.rev140714.nxm.of.udp.src.grouping.NxmOfUdpSrcBuilder in project genius by opendaylight.
the class NxMatchUdpSourcePort method populateBuilder.
@Override
protected void populateBuilder(NxmOfUdpSrcBuilder builder) {
builder.setPort(new PortNumber(port));
builder.setMask(mask);
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.match.rev140714.nxm.of.udp.src.grouping.NxmOfUdpSrcBuilder in project openflowplugin by opendaylight.
the class UdpSrcConvertor method convert.
@Override
public ExtensionAugment<? extends Augmentation<Extension>> convert(MatchEntry input, MatchPath path) {
UdpSrcCaseValue udpSrcCaseValue = (UdpSrcCaseValue) input.getMatchEntryValue();
NxmOfUdpSrcBuilder udpSrcBuilder = new NxmOfUdpSrcBuilder();
udpSrcBuilder.setPort(udpSrcCaseValue.getUdpSrcValues().getPort());
udpSrcBuilder.setMask(udpSrcCaseValue.getUdpSrcValues().getMask());
return resolveAugmentation(udpSrcBuilder.build(), path, NxmOfUdpSrcKey.class);
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.openflowplugin.extension.nicira.match.rev140714.nxm.of.udp.src.grouping.NxmOfUdpSrcBuilder in project openflowplugin by opendaylight.
the class UdpSrcConvertorTest method setUp.
@Before
public void setUp() throws Exception {
final NxmOfUdpSrcBuilder nxmOfUdpSrcBuilder = new NxmOfUdpSrcBuilder().setMask(1).setPort(DEFAULT_PORT);
final NxAugMatchNodesNodeTableFlowBuilder nxAugMatchNotifUpdateFlowStatsBuilder = new NxAugMatchNodesNodeTableFlowBuilder();
nxAugMatchNotifUpdateFlowStatsBuilder.setNxmOfUdpSrc(nxmOfUdpSrcBuilder.build());
final Augmentation<Extension> extensionAugmentation = nxAugMatchNotifUpdateFlowStatsBuilder.build();
when(extension.getAugmentation(Matchers.<Class<Augmentation<Extension>>>any())).thenReturn(extensionAugmentation);
udpSrcConvertor = new UdpSrcConvertor();
}
Aggregations