Getting a task response |
Under certain conditions you may want to evaluate the data received from the telnet server while the task was executing. To get this data invoke the TelnetTask#getResponse method.
Note
The value returned by TelnetTask#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(); |