2 * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.openflowplugin.extension.api.core.extension;
10 import org.opendaylight.openflowjava.protocol.api.keys.MessageTypeKey;
11 import org.opendaylight.openflowplugin.extension.api.ConverterExtensionKey;
12 import org.opendaylight.openflowplugin.extension.api.ConvertorActionFromOFJava;
13 import org.opendaylight.openflowplugin.extension.api.ConvertorActionToOFJava;
14 import org.opendaylight.openflowplugin.extension.api.ConvertorFromOFJava;
15 import org.opendaylight.openflowplugin.extension.api.ConvertorToOFJava;
16 import org.opendaylight.openflowplugin.extension.api.TypeVersionKey;
17 import org.opendaylight.openflowplugin.extension.api.path.AugmentationPath;
18 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
19 import org.opendaylight.yangtools.yang.binding.DataContainer;
24 public interface ExtensionConverterProvider {
29 * @return found converter
31 <FROM extends DataContainer, PATH extends AugmentationPath> ConvertorFromOFJava<FROM, PATH> getConverter(MessageTypeKey<?> key);
36 * @return found converter
38 <TO extends DataContainer> ConvertorToOFJava<TO> getConverter(ConverterExtensionKey<?> key);
42 * @return found converter
44 <FROM extends Action, TO extends DataContainer> ConvertorActionToOFJava<FROM, TO> getConverter(TypeVersionKey<FROM> key);
47 * lookup converter<br/>
48 * TODO: this method should be compatible with {@link #getConverter(MessageTypeKey)} after matches are migrated to similar structure
50 * @return found converter
52 <FROM extends DataContainer, PATH extends AugmentationPath> ConvertorActionFromOFJava<FROM, PATH> getActionConverter(MessageTypeKey<?> key);