EN
Ce contenu n’est pas disponible dans votre langue. Voici la version anglaise.
Ce sujet n'a pas encore été évalué - Évaluez ce sujet

Stream.Dispose Method

May 02, 2013

Releases all resources used by the Stream.

Namespace:  System.IO
Assembly:  mscorlib (in mscorlib.dll)
public void Dispose()

Implements

IDisposable.Dispose()

This method disposes the stream, by writing any changes to the backing store and closing the stream to release resources. 

Calling Dispose allows the resources used by the Stream to be reallocated for other purposes.

Notes to Implementers

Place all cleanup logic for your stream object in Stream.Dispose(Boolean). Do not override Close

Note that because of backward compatibility requirements, this method's implementation differs from the recommended guidance for the Dispose pattern.  This method calls Close, which then calls Stream.Dispose(Boolean).

Windows Phone OS

Supported in: 8.0, 7.1, 7.0

Windows Phone

Cela vous a-t-il été utile ?
(1500 caractères restants)
© 2013 Microsoft. Tous droits réservés.