Search in sources :

Example 1 with FlowMessageDeserializer

use of org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.FlowMessageDeserializer in project openflowplugin by opendaylight.

the class MessageDeserializerInjector method injectLegacyDeserializers.

@VisibleForTesting
static void injectLegacyDeserializers(final DeserializerExtensionProvider provider) {
    final Function<Integer, Function<Class<? extends OfHeader>, Consumer<OFDeserializer<? extends OfHeader>>>> injector = createInjector(provider, EncodeConstants.OF13_VERSION_ID);
    injector.apply(14).apply(FlowMessage.class).accept(new FlowMessageDeserializer());
    injector.apply(15).apply(GroupMessage.class).accept(new GroupMessageDeserializer());
    injector.apply(29).apply(MeterMessage.class).accept(new MeterMessageDeserializer());
    injector.apply(16).apply(PortMessage.class).accept(new PortMessageDeserializer());
}
Also used : OFDeserializer(org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer) MeterMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterMessage) GroupMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupMessage) GroupMessageDeserializer(org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.GroupMessageDeserializer) FlowMessageDeserializer(org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.FlowMessageDeserializer) Function(java.util.function.Function) PortMessageDeserializer(org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.PortMessageDeserializer) PortMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.port.rev130925.PortMessage) OfHeader(org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.OfHeader) MeterMessageDeserializer(org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.MeterMessageDeserializer) FlowMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.FlowMessage) VisibleForTesting(com.google.common.annotations.VisibleForTesting)

Aggregations

VisibleForTesting (com.google.common.annotations.VisibleForTesting)1 Function (java.util.function.Function)1 OFDeserializer (org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer)1 FlowMessageDeserializer (org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.FlowMessageDeserializer)1 GroupMessageDeserializer (org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.GroupMessageDeserializer)1 MeterMessageDeserializer (org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.MeterMessageDeserializer)1 PortMessageDeserializer (org.opendaylight.openflowplugin.impl.protocol.deserialization.messages.PortMessageDeserializer)1 PortMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.port.rev130925.PortMessage)1 FlowMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.FlowMessage)1 GroupMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupMessage)1 MeterMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterMessage)1 OfHeader (org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.OfHeader)1