Sending data |
To send data you may use the SshSession.Send, SshSession.SendWait, or SshSession.SendNoWait methods. The functionality and differences of these are described below.
Method |
Description |
SshSession.Send |
Sends command and waits for the session shell prompt to return.
Returns a string containing all data received from SSH server between the time the command was issued and the session shell prompt was received. |
SshSession.SendWait |
Sends command and waits for the specified prompt to return. This prompt may differ from the current session shell prompt.
Returns a string containing all data received from SSH server between the time the command was issued and the specified prompt was received.
|
SshSession.SendNoWait |
Sends command and immediately returns. This is useful in cases where you want to send an "exit" or "logout" command and no shell prompt is expected to return. |