Remove NetconfTopology
[netconf.git] / apps / callhome-provider / src / main / java / org / opendaylight / netconf / callhome / mount / CallHomeTopology.java
index 7f0c98884f71e21e4d661e65a3783cbdfa7221cb..d8efc31872ca723032d370a8360f051246d6c433 100644 (file)
@@ -7,6 +7,7 @@
  */
 package org.opendaylight.netconf.callhome.mount;
 
+import com.google.common.annotations.VisibleForTesting;
 import io.netty.util.concurrent.EventExecutor;
 import org.opendaylight.aaa.encrypt.AAAEncryptionService;
 import org.opendaylight.controller.config.threadpool.ScheduledThreadPool;
@@ -20,6 +21,8 @@ import org.opendaylight.netconf.client.mdsal.api.DeviceActionFactory;
 import org.opendaylight.netconf.client.mdsal.api.SchemaResourceManager;
 import org.opendaylight.netconf.client.mdsal.api.SslHandlerFactoryProvider;
 import org.opendaylight.netconf.topology.spi.AbstractNetconfTopology;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
 
 // Non-final for mocking
 public class CallHomeTopology extends AbstractNetconfTopology {
@@ -34,4 +37,13 @@ public class CallHomeTopology extends AbstractNetconfTopology {
             schemaRepositoryProvider, dataBroker, mountPointService, encryptionService, deviceActionFactory,
             baseSchemas, credentialProvider, sslHandlerFactoryProvider);
     }
+
+    void disconnectNode(final NodeId nodeId) {
+        deleteNode(nodeId);
+    }
+
+    @VisibleForTesting
+    public void connectNode(final Node node) {
+        ensureNode(node);
+    }
 }