IEncodingDetector::GetStreamEncoding Method (Stream^)

 

Attempts to detect the encoding associated with a stream.

Namespace:   Microsoft.VisualStudio.Text
Assembly:  Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)

Encoding^ GetStreamEncoding(
	Stream^ stream
)

Parameters

stream
Type: System.IO::Stream^

The stream to read.

Return Value

Type: System.Text::Encoding^

The detected encoding, or null if one could not be determined.

The stream is read from its current position. The encoding detector does not need to reset the stream's position.

Return to top
Show: