예제 #1
0
파일: Client.cs 프로젝트: noelhx/Telnet
 /// <summary>
 /// Reads from the stream.
 /// </summary>
 /// <param name="timeout">The timeout.</param>
 /// <returns>Any text read from the stream.</returns>
 public string Read(TimeSpan timeout)
 {
     ByteStreamHandler handler = new ByteStreamHandler(this.ByteStream, this.InternalCancellation);
       return handler.Read(timeout);
 }
예제 #2
0
파일: Client.cs 프로젝트: fireball87/Telnet
 /// <summary>
 /// Reads asynchronously from the stream.
 /// </summary>
 /// <param name="timeout">The timeout.</param>
 /// <returns>Any text read from the stream.</returns>
 public async Task<string> ReadAsync(TimeSpan timeout)
 {
   ByteStreamHandler handler = new ByteStreamHandler(this.ByteStream, this.InternalCancellation);
   return await handler.ReadAsync(timeout);
 }
예제 #3
0
 /// <summary>
 /// Reads from the stream.
 /// </summary>
 /// <param name="timeout">The timeout.</param>
 /// <returns>Any text read from the stream.</returns>
 public string Read(TimeSpan timeout)
 {
   ByteStreamHandler handler = new ByteStreamHandler(this.ByteStream);
   return handler.Read(timeout);
 }