C# 클래스 Mapsui.Geometries.WellKnownText.StreamTokenizer

The StreamTokenizer class takes an input stream and parses it into "tokens", allowing the tokens to be read one at a time. The parsing process is controlled by a table and a number of flags that can be set to various states. The stream tokenizer can recognize identifiers, numbers, quoted strings, and various comment style
This is a crude c# implementation of Java's StreamTokenizer class.
파일 보기 프로젝트 열기: pauldendulk/Mapsui

공개 메소드들

메소드 설명
GetNumericValue ( ) : double

If the current token is a number, this field contains the value of that number.

If the current token is a number, this field contains the value of that number. The current token is a number when the value of the ttype field is TT_NUMBER.

GetStringValue ( ) : string

If the current token is a word token, this field contains a string giving the characters of the word token.

GetTokenType ( ) : TokenType

Gets the token type of the current token.

NextToken ( ) : TokenType

Returns the next token.

NextToken ( bool ignoreWhitespaceAsToken ) : TokenType

Returns the next token.

StreamTokenizer ( TextReader reader, bool ignoreWhitespace ) : System

Initializes a new instance of the StreamTokenizer class.

비공개 메소드들

메소드 설명
GetType ( char character ) : TokenType

Determines a characters type (e.g. number, symbols, character).

NextNonWhitespaceToken ( ) : TokenType

Returns next token that is not whitespace.

NextTokenAny ( ) : TokenType

메소드 상세

GetNumericValue() 공개 메소드

If the current token is a number, this field contains the value of that number.
If the current token is a number, this field contains the value of that number. The current token is a number when the value of the ttype field is TT_NUMBER.
Current token is not a number in a valid format.
public GetNumericValue ( ) : double
리턴 double

GetStringValue() 공개 메소드

If the current token is a word token, this field contains a string giving the characters of the word token.
public GetStringValue ( ) : string
리턴 string

GetTokenType() 공개 메소드

Gets the token type of the current token.
public GetTokenType ( ) : TokenType
리턴 TokenType

NextToken() 공개 메소드

Returns the next token.
public NextToken ( ) : TokenType
리턴 TokenType

NextToken() 공개 메소드

Returns the next token.
public NextToken ( bool ignoreWhitespaceAsToken ) : TokenType
ignoreWhitespaceAsToken bool Determines is whitespace is ignored. True if whitespace is to be ignored.
리턴 TokenType

StreamTokenizer() 공개 메소드

Initializes a new instance of the StreamTokenizer class.
public StreamTokenizer ( TextReader reader, bool ignoreWhitespace ) : System
reader System.IO.TextReader A TextReader with some text to read.
ignoreWhitespace bool Flag indicating whether whitespace should be ignored.
리턴 System