An internal stream that can't close

Namespace: Contracts
Assembly: Contracts (in Contracts.dll)

Public Class NonClosingStream 
Inherits Stream
This language is not supported or no code example is available.
public class NonClosingStream : Stream
This language is not supported or no code example is available.
public ref class NonClosingStream : public Stream^
This language is not supported or no code example is available.
public class NonClosingStream 
extends Stream
This language is not supported or no code example is available.
Name Description
Public property CanRead When overridden in a derived class, gets a value indicating whether the current stream supports reading.
Public property CanSeek When overridden in a derived class, gets a value indicating whether the current stream supports seeking.
Public property CanTimeout Gets a value that determines whether the current stream can time out. (inherited from Stream).
Public property CanWrite When overridden in a derived class, gets a value indicating whether the current stream supports writing.
Public property Length When overridden in a derived class, gets the length in bytes of the stream.
Public property Position When overridden in a derived class, gets or sets the position within the current stream.
Public property ReadTimeout Gets or sets a value, in miliseconds, that determines how long the stream will attempt to read before timing out. (inherited from Stream).
Public property WriteTimeout Gets or sets a value, in miliseconds, that determines how long the stream will attempt to write before timing out. (inherited from Stream).
Top
Name Description
Public method BeginRead(Byte[], Int32, Int32, AsyncCallback, Object) Begins an asynchronous read operation. (Consider using ReadAsync instead; see the Remarks section.) (inherited from Stream).
Public method BeginWrite(Byte[], Int32, Int32, AsyncCallback, Object) Begins an asynchronous write operation. (Consider using WriteAsync instead; see the Remarks section.) (inherited from Stream).
Public method Close() Closes the current stream and releases any resources (such as sockets and file handles) associated with the current stream. Instead of calling this method, ensure that the stream is properly disposed.
Public method CopyTo(Stream, Int32) Reads the bytes from the current stream and writes them to another stream, using a specified buffer size. (inherited from Stream).
Public method CopyTo(Stream) Reads the bytes from the current stream and writes them to another stream. (inherited from Stream).
Public method CopyToAsync(Stream, Int32, CancellationToken) Asynchronously reads the bytes from the current stream and writes them to another stream, using a specified buffer size and cancellation token. (inherited from Stream).
Public method CopyToAsync(Stream) Asynchronously reads the bytes from the current stream and writes them to another stream. (inherited from Stream).
Public method CopyToAsync(Stream, Int32) Asynchronously reads the bytes from the current stream and writes them to another stream, using a specified buffer size. (inherited from Stream).
Public method CreateObjRef(Type) Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (inherited from MarshalByRefObject).
Protected method CreateWaitHandle Obsolete. Allocates a WaitHandle object. (inherited from Stream).
Public method Dispose Releases all resources used by the Stream. (System.IO.Stream).
Protected method Dispose(bool) Releases the unmanaged resources used by the Stream and optionally releases the managed resources.
Public method EndRead(IAsyncResult) Waits for the pending asynchronous read to complete. (Consider using ReadAsync instead; see the Remarks section.) (inherited from Stream).
Public method EndWrite(IAsyncResult) Ends an asynchronous write operation. (Consider using WriteAsync instead; see the Remarks section.) (inherited from Stream).
Public method Equals(Object) Determines whether the specified object is equal to the current object. (inherited from Object).
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (inherited from Object).
Public method 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.
Public method FlushAsync(CancellationToken) Asynchronously clears all buffers for this stream, causes any buffered data to be written to the underlying device, and monitors cancellation requests. (inherited from Stream).
Public method FlushAsync Asynchronously clears all buffers for this stream and causes any buffered data to be written to the underlying device. (inherited from Stream).
Public method GetHashCode Serves as the default hash function. (inherited from Object).
Public method GetLifetimeService Retrieves the current lifetime service object that controls the lifetime policy for this instance. (inherited from MarshalByRefObject).
Public method GetType Gets the Type of the current instance. (inherited from Object).
Public method InitializeLifetimeService Obtains a lifetime service object to control the lifetime policy for this instance. (inherited from MarshalByRefObject).
Protected method MemberwiseClone Creates a shallow copy of the current Object. (inherited from Object).
Protected method MemberwiseClone(Boolean) Creates a shallow copy of the current MarshalByRefObject object. (inherited from MarshalByRefObject).
Protected method ObjectInvariant Obsolete. Provides support for a Contract. (inherited from Stream).
Public method Read(Byte[], Int32, Int32) 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. (System.IO.Stream).
Public method 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.
Public method ReadAsync(Byte[], Int32, Int32, CancellationToken) Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests. (inherited from Stream).
Public method ReadAsync(Byte[], Int32, Int32) Asynchronously reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read. (inherited from Stream).
Public method ReadByte Reads a byte from the stream and advances the position within the stream by one byte, or returns -1 if at the end of the stream. (inherited from Stream).
Public method Seek(long, SeekOrigin) When overridden in a derived class, sets the position within the current stream.
Public method SetLength(long) When overridden in a derived class, sets the length of the current stream.
Public method ToString Returns a string that represents the current object. (inherited from Object).
Public method Write(Byte[], Int32, Int32) 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. (System.IO.Stream).
Public method 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.
Public method WriteAsync(Byte[], Int32, Int32, CancellationToken) Asynchronously writes a sequence of bytes to the current stream, advances the current position within this stream by the number of bytes written, and monitors cancellation requests. (inherited from Stream).
Public method WriteAsync(Byte[], Int32, Int32) Asynchronously writes a sequence of bytes to the current stream and advances the current position within this stream by the number of bytes written. (inherited from Stream).
Public method WriteByte(Byte) Writes a byte to the current position in the stream and advances the position within the stream by one byte. (inherited from Stream).
Top

.NET Framework

Supported in: 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1