Table of Contents

Class StreamOverStream

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

Implements stream which calls events after read/write operations. This class can be used for the debug purposes.

public class StreamOverStream : Stream, IAsyncDisposable, IDisposable
Inheritance
StreamOverStream
Implements
Extension Methods

Constructors

StreamOverStream(Stream?)

Initializes a new instance of the StreamOverStream class.

Properties

BaseStream

Gets or sets stream used to perform read/write operations.

CanRead

When overridden in a derived class, gets a value indicating whether the current stream supports reading.

CanSeek

When overridden in a derived class, gets a value indicating whether the current stream supports seeking.

CanWrite

When overridden in a derived class, gets a value indicating whether the current stream supports writing.

Length

When overridden in a derived class, gets the length in bytes of the stream.

Position

When overridden in a derived class, gets or sets the position within the current stream.

Methods

Flush()

When overridden in a derived class, clears all buffers for this stream and causes any buffered data to be written to the underlying device.

Read(byte[], int, int)

When overridden in a derived class, reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.

Seek(long, SeekOrigin)

When overridden in a derived class, sets the position within the current stream.

SetLength(long)

When overridden in a derived class, sets the length of the current stream.

Write(byte[], int, int)

When overridden in a derived class, writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.

Events

AfterRead

Occurs after read operation is performed in this object.

AfterWrite

Occurs after write operation is performed in this object.

GlobalAfterRead

Occurs after read operation is performed in any StreamOverStream object.

GlobalAfterWrite

Occurs after write operation is performed in any StreamOverStream object.