C# Class Ink.InkParser

Mostrar archivo Open project: inkle/ink Class Usage Examples

Public Methods

Method Description
CommandLineUserInput ( ) : CommandLineInput
InkParser ( string str, string filenameForMetadata = null, Ink externalErrorHandler = null ) : System
InkParser ( string str, string inkFilename = null, Ink externalErrorHandler = null, InkParser rootParser = null ) : System
OnError ( string message, int index, int lineIndex, bool isWarning ) : void
Parse ( ) : Story

Protected Methods

Method Description
AddOpenFilename ( string fullFilename ) : void
AuthorWarning ( ) : AuthorWarning
BracketedKnotDeclArguments ( ) : List
BracketedName ( ) : string
Choice ( ) : Choice
ChoiceCondition ( ) : Expression
ChoiceConditionsSpace ( ) : object
ChoiceSingleCondition ( ) : Expression
ConditionExpression ( ) : Expression
ConstDeclaration ( ) : Parsed.Object
ContentText ( ) : Text
ContentTextAllowingEcapeChar ( ) : Text
ContentTextNoEscape ( ) : string
DivertIdentifierWithArguments ( ) : Divert
ElseExpression ( ) : object
EndOfFile ( ) : object
EndOfLine ( ) : object
Expression ( ) : Expression
Expression ( int minimumPrecedence ) : Expression
ExpressionBool ( ) : Number
ExpressionDivertTarget ( ) : Expression
ExpressionFloat ( ) : Number
ExpressionFunctionCall ( ) : Expression
ExpressionFunctionCallArguments ( ) : List
ExpressionInfixRight ( Parsed left, InfixOperator op ) : Expression
ExpressionInt ( ) : Number
ExpressionLiteral ( ) : Expression
ExpressionNot ( ) : string
ExpressionParen ( ) : Expression
ExpressionString ( ) : StringExpression
ExpressionUnary ( ) : Expression
ExpressionVariableName ( ) : Expression
ExternalDeclaration ( ) : ExternalDeclaration
FlowDeclArgument ( ) : FlowBase.Argument
Gather ( ) : Gather
GatherDashes ( ) : object
GenerateStatementLevelRules ( ) : void
Glue ( ) : Parsed.Glue
Identifier ( ) : string
IncludeStatement ( ) : object
InlineConditionalBranches ( ) : List
InlineLogic ( ) : Parsed.Object
InlineLogicOrGlue ( ) : Parsed.Object
InnerConditionalContent ( ) : Conditional
InnerConditionalContent ( Expression initialQueryExpression ) : Conditional
InnerExpression ( ) : Parsed.Object
InnerInlineSequenceObjects ( ) : List
InnerLogic ( ) : Parsed.Object
InnerMultilineSequenceObjects ( ) : List
InnerSequence ( ) : Sequence
InnerSequenceObjects ( ) : List
KnotDeclaration ( ) : FlowDecl
KnotDefinition ( ) : Knot
KnotStitchNoContentRecoveryRule ( ) : object
KnotTitleEquals ( ) : string
Line ( ParseRule inlineRule ) : ParseRule
LineOfMixedTextAndLogic ( ) : List
LogicLine ( ) : Parsed.Object
MixedTextAndLogic ( ) : List
MultiDivert ( ) : List
MultilineConditionalBranches ( ) : List
MultilineWhitespace ( ) : object
Newline ( ) : object
ParseDashNotArrow ( ) : object
ParseDivertArrow ( ) : string
ParseDivertArrowOrTunnelOnwards ( ) : string
ParseTempKeyword ( ) : bool
ParseThreadArrow ( ) : string
PreProcessInputString ( string str ) : string
RegisterBinaryOperator ( string op, int precedence, bool requireWhitespace = false ) : void
RegisterExpressionOperators ( ) : void
RemoveOpenFilename ( string fullFilename ) : void
ReturnStatement ( ) : Return
RuleDidSucceed ( object result, StringParserState stateAtStart, StringParserState stateAtEnd ) : void
SequenceTypeAnnotation ( ) : object
SequenceTypeSymbolAnnotation ( ) : object
SequenceTypeWordAnnotation ( ) : object
SingleDivert ( ) : Divert
SingleMultilineCondition ( ) : ConditionalSingleBranch
SingleMultilineSequenceElement ( ) : ContentList
SkipToNextLine ( ) : object
Spaced ( ParseRule rule ) : ParseRule
StartThread ( ) : Divert
StatementAtLevel ( StatementLevel level ) : object
StatementsAtLevel ( StatementLevel level ) : List
StatementsBreakForLevel ( StatementLevel level ) : object
StitchDeclaration ( ) : FlowDecl
StitchDefinition ( ) : object
Tag ( ) : Parsed.Tag
Tags ( ) : List
TempDeclarationOrAssignment ( ) : Parsed.Object
TrimChoiceContent ( ContentList &content ) : void
VariableDeclaration ( ) : Parsed.Object
Whitespace ( ) : object

Private Methods

Method Description
DebugSource ( ) : CommandLineInput
DotSeparatedDivertPathComponents ( ) : List
FilenameIsAlreadyOpen ( string fullFilename ) : bool
ParseInfixOperator ( ) : InfixOperator
TrimEndWhitespace ( List mixedTextAndLogicResults, bool terminateWithSpace ) : void
UserChoiceNumber ( ) : CommandLineInput
UserImmediateModeStatement ( ) : CommandLineInput

Method Details

AddOpenFilename() protected method

protected AddOpenFilename ( string fullFilename ) : void
fullFilename string
return void

AuthorWarning() protected method

protected AuthorWarning ( ) : AuthorWarning
return AuthorWarning

BracketedKnotDeclArguments() protected method

protected BracketedKnotDeclArguments ( ) : List
return List

BracketedName() protected method

protected BracketedName ( ) : string
return string

Choice() protected method

protected Choice ( ) : Choice
return Choice

ChoiceCondition() protected method

protected ChoiceCondition ( ) : Expression
return Expression

ChoiceConditionsSpace() protected method

protected ChoiceConditionsSpace ( ) : object
return object

ChoiceSingleCondition() protected method

protected ChoiceSingleCondition ( ) : Expression
return Expression

CommandLineUserInput() public method

public CommandLineUserInput ( ) : CommandLineInput
return CommandLineInput

ConditionExpression() protected method

protected ConditionExpression ( ) : Expression
return Expression

ConstDeclaration() protected method

protected ConstDeclaration ( ) : Parsed.Object
return Parsed.Object

ContentText() protected method

protected ContentText ( ) : Text
return Ink.Parsed.Text

ContentTextAllowingEcapeChar() protected method

protected ContentTextAllowingEcapeChar ( ) : Text
return Ink.Parsed.Text

ContentTextNoEscape() protected method

protected ContentTextNoEscape ( ) : string
return string

DivertIdentifierWithArguments() protected method

protected DivertIdentifierWithArguments ( ) : Divert
return Divert

ElseExpression() protected method

protected ElseExpression ( ) : object
return object

EndOfFile() protected method

protected EndOfFile ( ) : object
return object

EndOfLine() protected method

protected EndOfLine ( ) : object
return object

Expression() protected method

protected Expression ( ) : Expression
return Expression

Expression() protected method

protected Expression ( int minimumPrecedence ) : Expression
minimumPrecedence int
return Expression

ExpressionBool() protected method

protected ExpressionBool ( ) : Number
return Number

ExpressionDivertTarget() protected method

protected ExpressionDivertTarget ( ) : Expression
return Expression

ExpressionFloat() protected method

protected ExpressionFloat ( ) : Number
return Number

ExpressionFunctionCall() protected method

protected ExpressionFunctionCall ( ) : Expression
return Expression

ExpressionFunctionCallArguments() protected method

protected ExpressionFunctionCallArguments ( ) : List
return List

ExpressionInfixRight() protected method

protected ExpressionInfixRight ( Parsed left, InfixOperator op ) : Expression
left Parsed
op InfixOperator
return Expression

ExpressionInt() protected method

protected ExpressionInt ( ) : Number
return Number

ExpressionLiteral() protected method

protected ExpressionLiteral ( ) : Expression
return Expression

ExpressionNot() protected method

protected ExpressionNot ( ) : string
return string

ExpressionParen() protected method

protected ExpressionParen ( ) : Expression
return Expression

ExpressionString() protected method

protected ExpressionString ( ) : StringExpression
return StringExpression

ExpressionUnary() protected method

protected ExpressionUnary ( ) : Expression
return Expression

ExpressionVariableName() protected method

protected ExpressionVariableName ( ) : Expression
return Expression

ExternalDeclaration() protected method

protected ExternalDeclaration ( ) : ExternalDeclaration
return ExternalDeclaration

FlowDeclArgument() protected method

protected FlowDeclArgument ( ) : FlowBase.Argument
return FlowBase.Argument

Gather() protected method

protected Gather ( ) : Gather
return Gather

GatherDashes() protected method

protected GatherDashes ( ) : object
return object

GenerateStatementLevelRules() protected method

protected GenerateStatementLevelRules ( ) : void
return void

Glue() protected method

protected Glue ( ) : Parsed.Glue
return Parsed.Glue

Identifier() protected method

protected Identifier ( ) : string
return string

IncludeStatement() protected method

protected IncludeStatement ( ) : object
return object

InkParser() public method

public InkParser ( string str, string filenameForMetadata = null, Ink externalErrorHandler = null ) : System
str string
filenameForMetadata string
externalErrorHandler Ink
return System

InkParser() public method

public InkParser ( string str, string inkFilename = null, Ink externalErrorHandler = null, InkParser rootParser = null ) : System
str string
inkFilename string
externalErrorHandler Ink
rootParser InkParser
return System

InlineConditionalBranches() protected method

protected InlineConditionalBranches ( ) : List
return List

InlineLogic() protected method

protected InlineLogic ( ) : Parsed.Object
return Parsed.Object

InlineLogicOrGlue() protected method

protected InlineLogicOrGlue ( ) : Parsed.Object
return Parsed.Object

InnerConditionalContent() protected method

protected InnerConditionalContent ( ) : Conditional
return Conditional

InnerConditionalContent() protected method

protected InnerConditionalContent ( Expression initialQueryExpression ) : Conditional
initialQueryExpression Expression
return Conditional

InnerExpression() protected method

protected InnerExpression ( ) : Parsed.Object
return Parsed.Object

InnerInlineSequenceObjects() protected method

protected InnerInlineSequenceObjects ( ) : List
return List

InnerLogic() protected method

protected InnerLogic ( ) : Parsed.Object
return Parsed.Object

InnerMultilineSequenceObjects() protected method

protected InnerMultilineSequenceObjects ( ) : List
return List

InnerSequence() protected method

protected InnerSequence ( ) : Sequence
return Sequence

InnerSequenceObjects() protected method

protected InnerSequenceObjects ( ) : List
return List

KnotDeclaration() protected method

protected KnotDeclaration ( ) : FlowDecl
return FlowDecl

KnotDefinition() protected method

protected KnotDefinition ( ) : Knot
return Knot

KnotStitchNoContentRecoveryRule() protected method

protected KnotStitchNoContentRecoveryRule ( ) : object
return object

KnotTitleEquals() protected method

protected KnotTitleEquals ( ) : string
return string

Line() protected method

protected Line ( ParseRule inlineRule ) : ParseRule
inlineRule ParseRule
return ParseRule

LineOfMixedTextAndLogic() protected method

protected LineOfMixedTextAndLogic ( ) : List
return List

LogicLine() protected method

protected LogicLine ( ) : Parsed.Object
return Parsed.Object

MixedTextAndLogic() protected method

protected MixedTextAndLogic ( ) : List
return List

MultiDivert() protected method

protected MultiDivert ( ) : List
return List

MultilineConditionalBranches() protected method

protected MultilineConditionalBranches ( ) : List
return List

MultilineWhitespace() protected method

protected MultilineWhitespace ( ) : object
return object

Newline() protected method

protected Newline ( ) : object
return object

OnError() public method

public OnError ( string message, int index, int lineIndex, bool isWarning ) : void
message string
index int
lineIndex int
isWarning bool
return void

Parse() public method

public Parse ( ) : Story
return Ink.Parsed.Story

ParseDashNotArrow() protected method

protected ParseDashNotArrow ( ) : object
return object

ParseDivertArrow() protected method

protected ParseDivertArrow ( ) : string
return string

ParseDivertArrowOrTunnelOnwards() protected method

protected ParseDivertArrowOrTunnelOnwards ( ) : string
return string

ParseTempKeyword() protected method

protected ParseTempKeyword ( ) : bool
return bool

ParseThreadArrow() protected method

protected ParseThreadArrow ( ) : string
return string

PreProcessInputString() protected method

protected PreProcessInputString ( string str ) : string
str string
return string

RegisterBinaryOperator() protected method

protected RegisterBinaryOperator ( string op, int precedence, bool requireWhitespace = false ) : void
op string
precedence int
requireWhitespace bool
return void

RegisterExpressionOperators() protected method

protected RegisterExpressionOperators ( ) : void
return void

RemoveOpenFilename() protected method

protected RemoveOpenFilename ( string fullFilename ) : void
fullFilename string
return void

ReturnStatement() protected method

protected ReturnStatement ( ) : Return
return Ink.Parsed.Return

RuleDidSucceed() protected method

protected RuleDidSucceed ( object result, StringParserState stateAtStart, StringParserState stateAtEnd ) : void
result object
stateAtStart StringParserState
stateAtEnd StringParserState
return void

SequenceTypeAnnotation() protected method

protected SequenceTypeAnnotation ( ) : object
return object

SequenceTypeSymbolAnnotation() protected method

protected SequenceTypeSymbolAnnotation ( ) : object
return object

SequenceTypeWordAnnotation() protected method

protected SequenceTypeWordAnnotation ( ) : object
return object

SingleDivert() protected method

protected SingleDivert ( ) : Divert
return Divert

SingleMultilineCondition() protected method

protected SingleMultilineCondition ( ) : ConditionalSingleBranch
return ConditionalSingleBranch

SingleMultilineSequenceElement() protected method

protected SingleMultilineSequenceElement ( ) : ContentList
return ContentList

SkipToNextLine() protected method

protected SkipToNextLine ( ) : object
return object

Spaced() protected method

protected Spaced ( ParseRule rule ) : ParseRule
rule ParseRule
return ParseRule

StartThread() protected method

protected StartThread ( ) : Divert
return Divert

StatementAtLevel() protected method

protected StatementAtLevel ( StatementLevel level ) : object
level StatementLevel
return object

StatementsAtLevel() protected method

protected StatementsAtLevel ( StatementLevel level ) : List
level StatementLevel
return List

StatementsBreakForLevel() protected method

protected StatementsBreakForLevel ( StatementLevel level ) : object
level StatementLevel
return object

StitchDeclaration() protected method

protected StitchDeclaration ( ) : FlowDecl
return FlowDecl

StitchDefinition() protected method

protected StitchDefinition ( ) : object
return object

Tag() protected method

protected Tag ( ) : Parsed.Tag
return Parsed.Tag

Tags() protected method

protected Tags ( ) : List
return List

TempDeclarationOrAssignment() protected method

protected TempDeclarationOrAssignment ( ) : Parsed.Object
return Parsed.Object

TrimChoiceContent() protected method

protected TrimChoiceContent ( ContentList &content ) : void
content ContentList
return void

VariableDeclaration() protected method

protected VariableDeclaration ( ) : Parsed.Object
return Parsed.Object

Whitespace() protected method

protected Whitespace ( ) : object
return object