Merge "builder class for NetconfServerSessionNegotiatorFactory"
[netconf.git] / netconf / netconf-topology / src / main / java / org / opendaylight / netconf / topology / NetconfTopology.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.netconf.topology;
10
11 import akka.actor.ActorContext;
12 import akka.actor.ActorRef;
13 import com.google.common.util.concurrent.ListenableFuture;
14 import org.opendaylight.controller.md.sal.binding.api.DataBroker;
15 import org.opendaylight.netconf.sal.connect.api.RemoteDeviceHandler;
16 import org.opendaylight.netconf.sal.connect.netconf.listener.NetconfDeviceCapabilities;
17 import org.opendaylight.netconf.sal.connect.netconf.listener.NetconfSessionPreferences;
18 import org.opendaylight.netconf.topology.pipeline.TopologyMountPointFacade.ConnectionStatusListenerRegistration;
19 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
20 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
21
22 public interface NetconfTopology {
23
24     String getTopologyId();
25
26     DataBroker getDataBroker();
27
28     ListenableFuture<NetconfDeviceCapabilities> connectNode(NodeId nodeId, Node configNode);
29
30     ListenableFuture<Void> disconnectNode(NodeId nodeId);
31
32     /**
33      * register master mount point
34      * @param context
35      * @param nodeId
36      */
37     void registerMountPoint(ActorContext context, NodeId nodeId);
38
39     /**
40      * register slave mountpoint with the provided ActorRef
41      * @param context
42      * @param nodeId
43      * @param masterRef
44      */
45     void registerMountPoint(ActorContext context, NodeId nodeId, ActorRef masterRef);
46
47     void unregisterMountPoint(NodeId nodeId);
48
49     ConnectionStatusListenerRegistration registerConnectionStatusListener(NodeId node, RemoteDeviceHandler<NetconfSessionPreferences> listener);
50 }