Skip to content

SSH.Channel.Read

Andrew Lambert edited this page Nov 11, 2022 · 8 revisions

SSH.Channel.Read

Method Signatures

 Function Read(Count As Integer, StreamID As Integer, encoding As TextEncoding = Nil) As String
 Private Function Read(Count As Integer, encoding As TextEncoding = Nil) As String Implements Readable.Read

Parameters

Name Type Comment
Count Integer The number of bytes to read.
StreamID Integer The stream to read from.
Encoding TextEncoding Optional. The TextEncoding of the data being read.

Return value

Returns a String containing the data that was read. When called on the Readable (or SSHStream) interface StreamID=0 will be used.

Remarks

Reads bytes from a stream within the channel if there is data available.

A channel has at least one and possibly several (up to 232) independent streams, identified by their stream ID. For example, if the channel represents the I/O streams of a program executing on the server then stream ID 0 represents its StdOut, while ID 1 represents its StdErr.

See also

Clone this wiki locally