Mastershipchange service implementation.
[openflowplugin.git] / openflowplugin-api / src / main / java / org / opendaylight / openflowplugin / api / openflow / statistics / StatisticsManager.java
1 /*
2  * Copyright (c) 2015 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.api.openflow.statistics;
10
11 import javax.annotation.Nonnull;
12 import org.opendaylight.openflowplugin.api.openflow.OFPManager;
13 import org.opendaylight.openflowplugin.api.openflow.configuration.ConfigurationProperty;
14 import org.opendaylight.openflowplugin.api.openflow.device.DeviceContext;
15 import org.opendaylight.openflowplugin.api.openflow.device.DeviceInfo;
16 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflow.provider.config.rev160510.OpenflowProviderConfig;
17
18 /**
19  * Manager to start or stop scheduling statistics.
20  */
21 public interface StatisticsManager extends OFPManager {
22
23     /**
24      * Start scheduling statistic gathering for given device info.
25      * @param deviceInfo for this device should be running statistics gathering
26      */
27     void startScheduling(DeviceInfo deviceInfo);
28
29     /**
30      * Stop scheduling statistic gathering for given device info.
31      * @param deviceInfo for this device should be stopped statistics gathering
32      */
33     void stopScheduling(DeviceInfo deviceInfo);
34
35     /**
36      * If plugin uses reconciliation framework. This is shortcut to
37      * {@link OpenflowProviderConfig#isUsingReconciliationFramework()}
38      * to avoid push {@link OpenflowProviderConfig} to each context.
39      * @return {@link ConfigurationProperty#USING_RECONCILIATION_FRAMEWORK}
40      * @since 0.5.0 Nitrogen
41      */
42     boolean isUsingReconciliationFramework();
43
44     @Override
45     void close();
46
47     StatisticsContext createContext(@Nonnull DeviceContext deviceContext);
48
49 }