Skip to content

Latest commit

 

History

History
51 lines (33 loc) · 1.69 KB

README.md

File metadata and controls

51 lines (33 loc) · 1.69 KB

UnicodeCharsetDetector

Latest build NuGet Downloads License

Table of Contents

Description

Text files Unicode charset w/wo BOM detector. Encodings supported:

  • UTF-7
  • UTF-8
  • UTF-16
  • UTF-32

Website

Download

NuGet

Example

Example application can be found here.

// Get file encoding.

var unicodeCharsetDetector = new UnicodeCharsetDetector.UnicodeCharsetDetector();

using var stream = File.OpenRead(fileName);

var charset = unicodeCharsetDetector.Check(stream);
var encoding = charset.ToEncoding();

License