BUG 2661 - sonar issues in learning-switch
[openflowplugin.git] / samples / learning-switch / src / main / java / org / opendaylight / openflowplugin / learningswitch / LearningSwitchManager.java
1 /**
2  * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8
9 package org.opendaylight.openflowplugin.learningswitch;
10
11 import org.opendaylight.controller.md.sal.binding.api.DataBroker;
12 import org.opendaylight.controller.sal.binding.api.NotificationService;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.packet.service.rev130709.PacketProcessingService;
14
15 /**
16  *
17  */
18 public interface LearningSwitchManager {
19
20     /**
21      * stop manager
22      */
23     void stop();
24
25     /**
26      * start manager
27      */
28     void start();
29
30     /**
31      * Set's Data Broker dependency.
32      * <p/>
33      * Data Broker is used to access overal operational and configuration
34      * tree.
35      * <p/>
36      * In simple Learning Switch handler, data broker is used to listen
37      * for changes in Openflow tables and to configure flows which will
38      * be provisioned down to the Openflow switch.
39      * <p/>
40      * inject {@link DataBroker}
41      *
42      * @param data
43      */
44     void setDataBroker(DataBroker data);
45
46     /**
47      * Set's Packet Processing dependency.
48      * <p/>
49      * Packet Processing service is used to send packet Out on Openflow
50      * switch.
51      * <p/>
52      * inject {@link PacketProcessingService}
53      *
54      * @param packetProcessingService
55      */
56     void setPacketProcessingService(
57             PacketProcessingService packetProcessingService);
58
59     /**
60      * Set's Notification service dependency.
61      * <p/>
62      * Notification service is used to register for listening
63      * packet-in notifications.
64      * <p/>
65      * inject {@link NotificationService}
66      *
67      * @param notificationService
68      */
69     void setNotificationService(NotificationService notificationService);
70 }