IEncodingDetector.GetStreamEncoding(Stream) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Attempts to detect an encoding associated with a stream.
public:
System::Text::Encoding ^ GetStreamEncoding(System::IO::Stream ^ stream);
public System.Text.Encoding GetStreamEncoding (System.IO.Stream stream);
abstract member GetStreamEncoding : System.IO.Stream -> System.Text.Encoding
Public Function GetStreamEncoding (stream As Stream) As Encoding
Parameters
- stream
- Stream
The stream to read.
Returns
The detected encoding, or null if one could not be determined.
Remarks
The stream is read from its current position. The encoding sniffer does not need to reset the stream's position.