Getting a task response |
Under certain conditions you may want to see the data received from the SSH server while the task was executing. To get this data invoke the SshTask#getResponse method. Note: The value returned by SshTask#getResponse may change if the task has not yet completed.
Example
// wait until task is complete while(!task.isComplete()) { Thread.sleep(100); }
// get response of completed task String response = task.getResponse(); |