aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/java/org/pacien/tincapp/commands/Tinc.kt')
-rw-r--r--app/src/main/java/org/pacien/tincapp/commands/Tinc.kt4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt
index 7f684c4..4d00805 100644
--- a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt
+++ b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt
@@ -43,6 +43,10 @@ object Tinc {
43 if (reachable) newCommand(netName).withArguments("dump", "reachable", "nodes") 43 if (reachable) newCommand(netName).withArguments("dump", "reachable", "nodes")
44 else newCommand(netName).withArguments("dump", "nodes")) 44 else newCommand(netName).withArguments("dump", "nodes"))
45 45
46 fun dumpSubnets(netName: String): CompletableFuture<List<String>> =
47 Executor.call(
48 newCommand(netName).withArguments("dump", "subnets"))
49
46 fun info(netName: String, node: String): CompletableFuture<String> = 50 fun info(netName: String, node: String): CompletableFuture<String> =
47 Executor.call(newCommand(netName).withArguments("info", node)) 51 Executor.call(newCommand(netName).withArguments("info", node))
48 .thenApply<String> { it.joinToString("\n") } 52 .thenApply<String> { it.joinToString("\n") }