Class OperationStream
Operational stream. Base class for cryptographic and compression streams.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Zip
Assembly: Telerik.Windows.Zip.dll
Syntax
public abstract class OperationStream : Stream, IDisposable
Properties
CanRead
Gets a value indicating whether the current stream supports reading.
Declaration
public override bool CanRead { get; }
Property Value
System.
|
Overrides
CanSeek
Gets a value indicating whether the current stream supports seeking.
Declaration
public override bool CanSeek { get; }
Property Value
System.
|
Overrides
CanWrite
Gets a value indicating whether the current stream supports writing.
Declaration
public override bool CanWrite { get; }
Property Value
System.
|
Overrides
HasFlushedFinalBlock
Gets a value which indicates whether the final buffer block has been written/read to/from the underlying stream.
Declaration
public bool HasFlushedFinalBlock { get; }
Property Value
System. true if the final block has been flushed or end of underlying stream is reached; otherwise, false. |
Length
Gets the length in bytes of the stream.
Declaration
public override long Length { get; }
Property Value
System.
|
Overrides
Position
Gets or sets the position within the current stream.
Declaration
public override long Position { get; set; }
Property Value
System.
|
Overrides
TotalPlainCount
Gets value which specify total plain bytes count (not-compressed and not-encrypted).
Declaration
public long TotalPlainCount { get; }
Property Value
System.
|
TotalTransformedCount
Gets value which specify total transformed bytes count (compressed or encrypted).
Declaration
public long TotalTransformedCount { get; }
Property Value
System.
|
Methods
Dispose(Boolean)
Releases the unmanaged resources used by the Stream and optionally releases the managed resources.
Declaration
protected override void Dispose(bool disposing)
Parameters
System. Value which indicates whether both managed and unmanaged resources (true) on only unmanaged resources (false) should be released. |
Overrides
EnsureNotDisposed()
Ensure that current stream is not disposed.
Declaration
protected void EnsureNotDisposed()
Finalize()
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
Declaration
protected void Finalize()
Flush()
Clears all buffers for this stream and causes any buffered data to be written to the underlying device.
Declaration
public override void Flush()
Overrides
Read(Byte[], Int32, Int32)
Reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.
Declaration
public override int Read(byte[] buffer, int offset, int count)
Parameters
System. An array of bytes. When this method returns, the buffer contains the specified byte array with the values between offset and (offset + count - 1) replaced by the bytes read from the current source. |
System. The zero-based byte offset in buffer at which to begin storing the data read from the current stream. |
System. The maximum number of bytes to be read from the current stream. |
Returns
System. The total number of bytes read into the buffer. This can be less than the number of bytes requested if that many bytes are not currently available, or zero (0) if the end of the stream has been reached. |
Overrides
Exceptions
System. The Stream |
System. The |
System. The sum of the |
Read(Byte[], Int32, Int32, CancellationToken)
Reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read.
Declaration
protected int Read(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Parameters
System. An array of bytes. When this method returns, the buffer contains the specified byte array with the values between offset and (offset + count - 1) replaced by the bytes read from the current source. |
System. The zero-based byte offset in buffer at which to begin storing the data read from the current stream. |
System. The maximum number of bytes to be read from the current stream. |
System. The cancellation token used to cancel the operation |
Returns
System. The total number of bytes read into the buffer. This can be less than the number of bytes requested if that many bytes are not currently available, or zero (0) if the end of the stream has been reached. |
Exceptions
System. The Stream |
System. The |
System. The sum of the |
Seek(Int64, SeekOrigin)
Sets the position within the current stream.
Declaration
public override long Seek(long offset, SeekOrigin origin)
Parameters
System. A byte offset relative to the origin parameter. |
System. A value of type SeekOrigin indicating the reference point used to obtain the new position. |
Returns
System. The new position within the current stream. |
Overrides
SetLength(Int64)
Sets the length of the current stream.
Declaration
public override void SetLength(long value)
Parameters
System. The desired length of the current stream in bytes. |
Overrides
Write(Byte[], Int32, Int32)
Writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written.
Declaration
public override void Write(byte[] buffer, int offset, int count)
Parameters
System. An array of bytes. This method copies count bytes from buffer to the current stream. |
System. The zero-based byte offset in buffer at which to begin copying bytes to the current stream. |
System. The number of bytes to be written to the current stream. |