AMPS C# Client  5.3.5.0
AMPS C# Client for .NET
AMPS.Client.HandleTimeoutStream Class Reference

A Stream implementation that wraps a NetworkStream to keep timeout exceptions from escaping Read and causing the connection to close More...

+ Inheritance diagram for AMPS.Client.HandleTimeoutStream:

Public Member Functions

 HandleTimeoutStream (NetworkStream stream_, TCPTransportImpl transport_)
 Create a wrapper around stream_ that will notify transport_ of any timeouts and swallow those exceptions. More...
 
override int Read (byte[] buffer, int offset, int count)
 
void setBlockTimeout (bool blockTimeout_)
 
override IAsyncResult BeginRead (byte[] buffer, int offset, int size, AsyncCallback callback, object state)
 
override IAsyncResult BeginWrite (byte[] buffer, int offset, int size, AsyncCallback callback, object state)
 
void Close (int timeout)
 
override int EndRead (IAsyncResult asyncResult)
 
override void EndWrite (IAsyncResult asyncResult)
 
override void Flush ()
 
override long Seek (long offset, SeekOrigin origin)
 
override void SetLength (long value)
 
override void Write (byte[] buffer, int offset, int count)
 

Properties

override bool CanRead [get]
 
override bool CanSeek [get]
 
override bool CanTimeout [get]
 
override bool CanWrite [get]
 
virtual bool DataAvailable [get]
 
override long Length [get]
 
override long Position [get, set]
 
override int ReadTimeout [get, set]
 
override int WriteTimeout [get, set]
 

Detailed Description

A Stream implementation that wraps a NetworkStream to keep timeout exceptions from escaping Read and causing the connection to close

Constructor & Destructor Documentation

◆ HandleTimeoutStream()

AMPS.Client.HandleTimeoutStream.HandleTimeoutStream ( NetworkStream  stream_,
TCPTransportImpl  transport_ 
)
inline

Create a wrapper around stream_ that will notify transport_ of any timeouts and swallow those exceptions.

Parameters
stream_The NetworkStream to wrap and prevent timeout exceptions from escaping
transport_The TCPTransportImpl to notify of timeout events when they occur.

The documentation for this class was generated from the following file: