Back to product page

PeekLine method


Receives incoming line without removing it from the buffer.

Type

String

Syntax

  • C#
  • VB.NET
public String PeekLine();
The PeekLine() syntax has these parts:
Return valueNew string with received text.

public Function PeekLine() As String
The PeekLine() syntax has these parts:
Return valueNew string with received text.

Remarks

PeekLine method will return full line of text if it exists in incoming buffer, but will not remove it from the buffer. wodSSH.NET will remove end-of-line markers (CR/LF) so you don't need to trim this string by yourself. If no line is found, wodSSH.NET will throw an "None found" exception, and will not wait for data to arrive.

To actually remove data from the incoming buffer, you should use Receive or ReceiveLine methods.

Platforms

Windows