import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.UdpSrc;
import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.VlanPcp;
import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.VlanVid;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.oxm.fields.MatchEntries;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.oxm.fields.MatchEntriesBuilder;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.match.grouping.Match;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.match.grouping.MatchBuilder;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.match.grouping.Match;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.match.grouping.MatchBuilder;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.oxm.fields.grouping.MatchEntries;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.oxm.rev130731.oxm.fields.grouping.MatchEntriesBuilder;
import com.google.common.base.Joiner;
return matchEntriesList;
}
+ /** Decodes oxm ids
+ * @param in input ByteBuf
+ * @param matchLength match entries length
+ * @return list of match ids
+ */
+ public static List<MatchEntries> createMatchIds(ByteBuf in, int matchLength) {
+ return MatchIdsDeserializer.createOxmIds(in, matchLength);
+ }
+
private static void addMaskAugmentation(MatchEntriesBuilder builder, ByteBuf in, int matchEntryLength) {
MaskMatchEntryBuilder maskBuilder = new MaskMatchEntryBuilder();
byte[] mask = new byte[matchEntryLength];
private static void addMetadataAugmentation(MatchEntriesBuilder builder, ByteBuf in) {
MetadataMatchEntryBuilder metadata = new MetadataMatchEntryBuilder();
- byte[] metadataBytes = new byte[Long.SIZE/Byte.SIZE];
+ byte[] metadataBytes = new byte[EncodeConstants.SIZE_OF_LONG_IN_BYTES];
in.readBytes(metadataBytes);
metadata.setMetadata(metadataBytes);
builder.addAugmentation(MetadataMatchEntry.class, metadata.build());