Nitro.Handlers Class Reference

Detailed Description

Used when parsing code into code fragments. This class figures out what type of fragment we have next in order for that type to 'handle' the text from the code.

Static Public Member Functions

static Handler Find (char peek)
 Finds which type of fragment will accept and handle the given character. More...
 
static CodeFragment Handle (Handler handle, CodeLexer sr)
 Reads a code fragment from the code using a known handler. More...
 

Member Function Documentation

static Handler Nitro.Handlers.Find ( char  peek)
inlinestatic

Finds which type of fragment will accept and handle the given character.

Parameters
peekThe character to find a handler for.
Returns
The handler which will deal with this character. May also be told to stop if no handler is available.
static CodeFragment Nitro.Handlers.Handle ( Handler  handle,
CodeLexer  sr 
)
inlinestatic

Reads a code fragment from the code using a known handler.

Parameters
handleThe handler to use.
srThe raw code stream
Returns
A new code fragment, or null if told to stop with Handler.Stop.