public class KarafShell extends Object
Constructor and Description |
---|
KarafShell(InetSocketAddress sshAddress) |
KarafShell(InetSocketAddress sshAddress,
String username,
String password) |
Modifier and Type | Method and Description |
---|---|
KarafShell |
runCommand(String command)
Is the same as
runCommand(command, null . |
KarafShell |
runCommand(String command,
java.util.function.Function<String,Boolean> verifyOutputFunction)
Runs the given command in the karaf shell.
|
KarafShell |
verifyLog(java.util.function.Function<String,Boolean> function)
Is the same as
runCommand(null, function) . |
public KarafShell(InetSocketAddress sshAddress)
public KarafShell(InetSocketAddress sshAddress, String username, String password)
public KarafShell runCommand(String command, java.util.function.Function<String,Boolean> verifyOutputFunction)
function
verifies the output.command
- the command to run, e.g. "features:list"verifyOutputFunction
- An optional function to verify the output, e.g. to check for certain log messagespublic KarafShell runCommand(String command)
runCommand(command, null
.runCommand(String, Function)
public KarafShell verifyLog(java.util.function.Function<String,Boolean> function)
runCommand(null, function)
.runCommand(String, Function)
Copyright © 2022. All rights reserved.