added feature odl-openflowplugin-new-southbound
[openflowplugin.git] / openflowplugin-impl / src / main / java / org / opendaylight / openflowplugin / impl / OpenFlowPluginProviderImpl.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.impl;
10
11
12 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker;
13 import org.opendaylight.openflowjava.protocol.spi.connection.SwitchConnectionProvider;
14 import org.opendaylight.openflowplugin.api.openflow.OpenFlowPluginProvider;
15 import org.opendaylight.openflowplugin.api.openflow.device.DeviceManager;
16 import org.opendaylight.openflowplugin.api.openflow.rpc.RpcManager;
17 import org.opendaylight.openflowplugin.api.openflow.statistics.StatisticsManager;
18 import org.opendaylight.openflowplugin.impl.device.DeviceManagerImpl;
19 import org.opendaylight.openflowplugin.impl.rpc.RpcManagerImpl;
20 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflowplugin.api.types.rev150327.OfpRole;
21 import java.util.Collection;
22
23 /**
24  * Created by Martin Bobak <mbobak@cisco.com> on 27.3.2015.
25  */
26 public class OpenFlowPluginProviderImpl implements OpenFlowPluginProvider {
27
28     private DeviceManager deviceManager;
29     private RpcManager rpcManager;
30     private BindingAwareBroker.ProviderContext providerContext;
31     private StatisticsManager statisticsManager;
32
33     @Override
34     public void onSessionInitiated(final BindingAwareBroker.ProviderContext session) {
35         providerContext = session;
36     }
37
38     @Override
39     public void setSwitchConnectionProviders(final Collection<SwitchConnectionProvider> switchConnectionProvider) {
40
41     }
42
43     @Override
44     public void setRole(final OfpRole role) {
45
46     }
47
48     @Override
49     public void initialize() {
50         deviceManager = new DeviceManagerImpl();
51         rpcManager = new RpcManagerImpl(providerContext);
52         //TODO : initialize statistics manager
53     }
54
55     @Override
56     public void close() throws Exception {
57
58     }
59 }