C# Class Ikayzo.SDL.Parser

Mostra file Open project: ikayzo/SDL.NET Class Usage Examples

Private Methods

Method Description
AddChildren ( Tag parent ) : void
AddEscapedCharInString ( char c ) : void
AddTagAttributes ( Tag tag, List toks, int tpos ) : void

Add the attributes

AddTagValues ( Tag tag, List toks, int tpos ) : int

Add the values

Combine ( SDLDateTime dt, TimeSpanWithZone tswz ) : SDLDateTime

Combine a SDLDateTime (date only) with a TimeSpanWithZone to create a date-time

ConstructTag ( List toks ) : Tag

Construct a tag (but not its children) from a string of tokens

ExpectingButGot ( string expecting, object got, int line, int position ) : void

Close the reader and throw a SDLParseException using the format "Was expecting X but got Y"

GetLineTokens ( ) : List

Get a line as tokens. This method handles line continuations both within and outside String literals.

HandleBackQuoteString ( ) : void
HandleBinaryLiteral ( ) : void
HandleCharacterLiteral ( ) : void
HandleDoubleQuoteString ( ) : void
HandleEscapedDoubleQuotedString ( ) : void
HandleIdentifier ( ) : void
HandleLineContinuation ( ) : void
HandleNumberDateOrTimeSpan ( ) : void
HandleSlashComment ( ) : void
Parse ( ) : IList

Parse the reader and create a list of tags

ParseBinary ( string literal ) : byte[]
ParseCharacter ( string literal ) : Char
ParseDate ( string literal ) : SDLDateTime
ParseDateTime ( string literal ) : SDLDateTime
ParseException ( string description, int line, int position ) : void

Close the reader and throw a SDLParseException

ParseNumber ( string literal ) : object
ParseString ( string literal ) : string
ParseTimeSpan ( string literal ) : System.TimeSpan
Parser ( TextReader reader ) : System

Create an SDL parser

ReadLine ( ) : string

Skips comment lines and blank lines.

ReadRawLine ( ) : string

Reads a "raw" line including lines with comments and blank lines

ReverseIfPositive ( int val ) : int