X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fprotocol_plugins%2Fopenflow_netty%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fprotocol_plugin%2Fopenflow%2Finternal%2FFlowProgrammerNotifier.java;fp=opendaylight%2Fprotocol_plugins%2Fopenflow_netty%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fprotocol_plugin%2Fopenflow%2Finternal%2FFlowProgrammerNotifier.java;h=0000000000000000000000000000000000000000;hb=9f1c9e42abe1546fe352a9960935271f47f9a775;hp=2a62d6c34a08a19c4cccb898acdf90945ada255b;hpb=85073423c6069e4b58fffde7cf19c806b2b52dd5;p=controller.git diff --git a/opendaylight/protocol_plugins/openflow_netty/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowProgrammerNotifier.java b/opendaylight/protocol_plugins/openflow_netty/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowProgrammerNotifier.java deleted file mode 100644 index 2a62d6c34a..0000000000 --- a/opendaylight/protocol_plugins/openflow_netty/src/main/java/org/opendaylight/controller/protocol_plugin/openflow/internal/FlowProgrammerNotifier.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0 which accompanies this distribution, - * and is available at http://www.eclipse.org/legal/epl-v10.html - */ - -package org.opendaylight.controller.protocol_plugin.openflow.internal; - -import org.apache.felix.dm.Component; -import org.opendaylight.controller.protocol_plugin.openflow.IFlowProgrammerNotifier; -import org.opendaylight.controller.sal.core.Node; -import org.opendaylight.controller.sal.flowprogrammer.Flow; -import org.opendaylight.controller.sal.flowprogrammer.IPluginOutFlowProgrammerService; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** - * Flow Programmer Notifier class for relaying asynchronous messages received - * from the network node to the listeners on the proper container - */ -public class FlowProgrammerNotifier implements IFlowProgrammerNotifier { - protected static final Logger logger = LoggerFactory - .getLogger(FlowProgrammerNotifier.class); - private IPluginOutFlowProgrammerService salNotifier; - - public FlowProgrammerNotifier() { - salNotifier = null; - } - - void init(Component c) { - logger.debug("INIT called!"); - } - - /** - * Function called by the dependency manager when at least one dependency - * become unsatisfied or when the component is shutting down because for - * example bundle is being stopped. - * - */ - void destroy() { - logger.debug("DESTROY called!"); - } - - /** - * Function called by dependency manager after "init ()" is called and after - * the services provided by the class are registered in the service registry - * - */ - void start() { - logger.debug("START called!"); - } - - /** - * Function called by the dependency manager before the services exported by - * the component are unregistered, this will be followed by a "destroy ()" - * calls - * - */ - void stop() { - logger.debug("STOP called!"); - } - - public void setPluginOutFlowProgrammerService( - IPluginOutFlowProgrammerService s) { - this.salNotifier = s; - } - - public void unsetPluginOutFlowProgrammerService( - IPluginOutFlowProgrammerService s) { - if (this.salNotifier == s) { - this.salNotifier = null; - } - } - - @Override - public void flowRemoved(Node node, Flow flow) { - if (salNotifier != null) { - salNotifier.flowRemoved(node, flow); - } else { - logger.warn("Unable to relay switch message to upper layer"); - } - } - - @Override - public void flowErrorReported(Node node, long rid, Object err) { - if (salNotifier != null) { - salNotifier.flowErrorReported(node, rid, err); - } else { - logger.warn("Unable to relay switch error message to upper layer"); - } - } - -}