C# Class Akka.Configuration.Hocon.HoconTokenizer

This class contains methods used to tokenize HOCON (Human-Optimized Config Object Notation) configuration strings.
Inheritance: Tokenizer
Show file Open project: rogeralsing/akka.net Class Usage Examples

Public Methods

Method Description
HoconTokenizer ( string text ) : System

Initializes a new instance of the HoconTokenizer class.

IsArrayEnd ( ) : bool

Determines whether the current token matches an TokenType.ArrayEnd token.

IsArrayStart ( ) : bool

Determines whether the current token matches an TokenType.ArrayStart token.

IsAssignment ( ) : bool

Determines whether the current token matches an TokenType.Assign token.

IsComma ( ) : bool

Determines whether the current token matches an TokenType.Comma token.

IsDot ( ) : bool

Determines whether the current token matches an TokenType.Dot token.

IsEndOfObject ( ) : bool

Determines whether the current token matches an TokenType.ObjectEnd token.

IsInclude ( ) : bool
IsObjectStart ( ) : bool

Determines whether the current token matches an TokenType.ObjectStart token.

IsSpaceOrTab ( ) : bool

Determines whether the current token is a space or a tab.

IsStartOfComment ( ) : bool
IsStartOfQuotedText ( ) : bool

Determines whether the current token matches the start of a quoted string.

IsStartOfTripleQuotedText ( ) : bool

Determines whether the current token matches the start of a triple quoted string.

IsStartSimpleValue ( ) : bool

Determines whether the current token is the start of an unquoted string literal.

IsSubstitutionStart ( ) : bool

Determines whether the current token is the start of a substitution.

IsUnquotedKey ( ) : bool

Determines whether the current token is an unquoted key.

IsUnquotedKeyStart ( ) : bool

Determines whether the current token is the start of an unquoted key.

IsWhitespace ( ) : bool
IsWhitespaceOrComment ( ) : bool
PullArrayEnd ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.ArrayEnd token from the tokenizer's current position.

PullArrayStart ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.ArrayStart token from the tokenizer's current position.

PullAssignment ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.Assign token from the tokenizer's current position.

PullComma ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.Comma token from the tokenizer's current position.

PullComment ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.Comment token from the tokenizer's current position.

PullDot ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.Dot token from the tokenizer's current position.

PullEndOfObject ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.ObjectEnd token from the tokenizer's current position.

PullInclude ( ) : Akka.Configuration.Hocon.Token
PullNext ( ) : Akka.Configuration.Hocon.Token

Retrieves the next token from the string.

PullQuotedKey ( ) : Akka.Configuration.Hocon.Token

Retrieves a quoted TokenType.Key token from the tokenizer's current position.

PullQuotedText ( ) : Akka.Configuration.Hocon.Token

Retrieves a quoted TokenType.LiteralValue token from the tokenizer's current position.

PullRestOfLine ( ) : string

Retrieves the current line from where the current token is located in the string.

PullSimpleValue ( ) : Akka.Configuration.Hocon.Token

Retrieves the current token as a string literal token.

PullSpaceOrTab ( ) : Akka.Configuration.Hocon.Token

Retrieves the current token, including whitespace and tabs, as a string literal token.

PullStartOfObject ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.ObjectStart token from the tokenizer's current position.

PullSubstitution ( ) : Akka.Configuration.Hocon.Token

Retrieves a TokenType.Substitute token from the tokenizer's current position.

PullTripleQuotedText ( ) : Akka.Configuration.Hocon.Token

Retrieves a triple quoted TokenType.LiteralValue token from the tokenizer's current position.

PullUnquotedKey ( ) : Akka.Configuration.Hocon.Token

Retrieves an unquoted TokenType.Key token from the tokenizer's current position.

PullValue ( ) : Akka.Configuration.Hocon.Token

Retrieves a value token from the tokenizer's current position.

PullWhitespaceAndComments ( ) : void

Advances the tokenizer to the next non-whitespace, non-comment token.

Private Methods

Method Description
IsStartOfQuotedKey ( ) : bool
IsUnquotedText ( ) : bool
IsValue ( ) : bool

Determines whether the current token is a value.

PullEscapeSequence ( ) : string
PullUnquotedText ( ) : Akka.Configuration.Hocon.Token

Method Details

HoconTokenizer() public method

Initializes a new instance of the HoconTokenizer class.
public HoconTokenizer ( string text ) : System
text string The string that contains the text to tokenize.
return System

IsArrayEnd() public method

Determines whether the current token matches an TokenType.ArrayEnd token.
public IsArrayEnd ( ) : bool
return bool

IsArrayStart() public method

Determines whether the current token matches an TokenType.ArrayStart token.
public IsArrayStart ( ) : bool
return bool

IsAssignment() public method

Determines whether the current token matches an TokenType.Assign token.
public IsAssignment ( ) : bool
return bool

IsComma() public method

Determines whether the current token matches an TokenType.Comma token.
public IsComma ( ) : bool
return bool

IsDot() public method

Determines whether the current token matches an TokenType.Dot token.
public IsDot ( ) : bool
return bool

IsEndOfObject() public method

Determines whether the current token matches an TokenType.ObjectEnd token.
public IsEndOfObject ( ) : bool
return bool

IsInclude() public method

public IsInclude ( ) : bool
return bool

IsObjectStart() public method

Determines whether the current token matches an TokenType.ObjectStart token.
public IsObjectStart ( ) : bool
return bool

IsSpaceOrTab() public method

Determines whether the current token is a space or a tab.
public IsSpaceOrTab ( ) : bool
return bool

IsStartOfComment() public method

public IsStartOfComment ( ) : bool
return bool

IsStartOfQuotedText() public method

Determines whether the current token matches the start of a quoted string.
public IsStartOfQuotedText ( ) : bool
return bool

IsStartOfTripleQuotedText() public method

Determines whether the current token matches the start of a triple quoted string.
public IsStartOfTripleQuotedText ( ) : bool
return bool

IsStartSimpleValue() public method

Determines whether the current token is the start of an unquoted string literal.
public IsStartSimpleValue ( ) : bool
return bool

IsSubstitutionStart() public method

Determines whether the current token is the start of a substitution.
public IsSubstitutionStart ( ) : bool
return bool

IsUnquotedKey() public method

Determines whether the current token is an unquoted key.
public IsUnquotedKey ( ) : bool
return bool

IsUnquotedKeyStart() public method

Determines whether the current token is the start of an unquoted key.
public IsUnquotedKeyStart ( ) : bool
return bool

IsWhitespace() public method

public IsWhitespace ( ) : bool
return bool

IsWhitespaceOrComment() public method

public IsWhitespaceOrComment ( ) : bool
return bool

PullArrayEnd() public method

Retrieves a TokenType.ArrayEnd token from the tokenizer's current position.
public PullArrayEnd ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullArrayStart() public method

Retrieves a TokenType.ArrayStart token from the tokenizer's current position.
public PullArrayStart ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullAssignment() public method

Retrieves a TokenType.Assign token from the tokenizer's current position.
public PullAssignment ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullComma() public method

Retrieves a TokenType.Comma token from the tokenizer's current position.
public PullComma ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullComment() public method

Retrieves a TokenType.Comment token from the tokenizer's current position.
public PullComment ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullDot() public method

Retrieves a TokenType.Dot token from the tokenizer's current position.
public PullDot ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullEndOfObject() public method

Retrieves a TokenType.ObjectEnd token from the tokenizer's current position.
public PullEndOfObject ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullInclude() public method

public PullInclude ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullNext() public method

Retrieves the next token from the string.
/// This exception is thrown when an unknown token is encountered. ///
public PullNext ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullQuotedKey() public method

Retrieves a quoted TokenType.Key token from the tokenizer's current position.
public PullQuotedKey ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullQuotedText() public method

Retrieves a quoted TokenType.LiteralValue token from the tokenizer's current position.
public PullQuotedText ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullRestOfLine() public method

Retrieves the current line from where the current token is located in the string.
public PullRestOfLine ( ) : string
return string

PullSimpleValue() public method

Retrieves the current token as a string literal token.
/// This exception is thrown when the tokenizer cannot find /// a string literal value from the current token. ///
public PullSimpleValue ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullSpaceOrTab() public method

Retrieves the current token, including whitespace and tabs, as a string literal token.
public PullSpaceOrTab ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullStartOfObject() public method

Retrieves a TokenType.ObjectStart token from the tokenizer's current position.
public PullStartOfObject ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullSubstitution() public method

Retrieves a TokenType.Substitute token from the tokenizer's current position.
public PullSubstitution ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullTripleQuotedText() public method

Retrieves a triple quoted TokenType.LiteralValue token from the tokenizer's current position.
public PullTripleQuotedText ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullUnquotedKey() public method

Retrieves an unquoted TokenType.Key token from the tokenizer's current position.
public PullUnquotedKey ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullValue() public method

Retrieves a value token from the tokenizer's current position.
/// Expected value: Null literal, Array, Quoted Text, Unquoted Text, /// Triple quoted Text, Object or End of array ///
public PullValue ( ) : Akka.Configuration.Hocon.Token
return Akka.Configuration.Hocon.Token

PullWhitespaceAndComments() public method

Advances the tokenizer to the next non-whitespace, non-comment token.
public PullWhitespaceAndComments ( ) : void
return void