C# Class GettextLib.ExpressionEvaluator.Scanner.Guesser

This class provides a simple finite state automaton that scans the file looking for (1) valid UTF-8 byte patterns, (2) bytes >= 0x80 which are not part of a UTF-8 sequence. The method then guesses whether it is UTF-8 or maybe some local machine default encoding. This works well for the various Latin encodings.
显示文件 Open project: while-true/gettext

Public Properties

Property Type Description
uppr long
utfX long

Public Methods

Method Description
GuessCodePage ( ) : int
Guesser ( System file ) : System
SetSource ( System source ) : void

Private Methods

Method Description
Guesser ( ) : System
NextState ( ) : int
Scan ( ) : int

Method Details

GuessCodePage() public method

public GuessCodePage ( ) : int
return int

Guesser() public method

public Guesser ( System file ) : System
file System
return System

SetSource() public method

public SetSource ( System source ) : void
source System
return void

Property Details

uppr public_oe property

public long uppr
return long

utfX public_oe property

public long utfX
return long