Properties

$allowsMutation

$allowsMutation

$wysiwyg

$wysiwyg

$scripts

$scripts

$renderer

$renderer

$expressionInstantiator

$expressionInstantiator

$lexerErrors

$lexerErrors

$parserErrors

$parserErrors

$symbols

$symbols

$terminals

$terminals

$productions

$productions

$table

$table

$defaultActions

$defaultActions

$version

$version

$debug

$debug

$none

$none

$shift

$shift

$reduce

$reduce

$accept

$accept

$eof

$eof

$yy

$yy

$match

$match

$conditionStack

$conditionStack

$conditionStackCount

$conditionStackCount

$rules

$rules

$conditions

$conditions

$done

$done

$less

$less

$more

$more

$input

$input

$offset

$offset

$ranges

$ranges

$flex

$flex

$types

$types : \WikiLingo\Expression\*[]

Type

\WikiLingo\Expression\*[]

$typesCount

$typesCount : array

Type

array

$skipExpressions

$skipExpressions : bool

Type

bool

$pluginStack

$pluginStack

$pluginStackCount

$pluginStackCount

$pluginInstances

$pluginInstances

$plugins

$plugins : \WikiLingo\Plugin\*[]

Type

\WikiLingo\Plugin\*[]

$originalInput

$originalInput : string

Type

string

$linkStack

$linkStack

$blocks

$blocks : \WikiLingo\Expression\Block[]

Type

\WikiLingo\Expression\Block[]

$blocksLength

$blocksLength

$tableStack

$tableStack

$verbose

$verbose

$parsing

$parsing

$pcreRecursionLimit

$pcreRecursionLimit

Methods

__construct()

__construct()

parse()

parse( $input)

Parameters

$input

preParse()

preParse(mixed $input)

Event just before $this->parse($input), used to ready parser, ensuring defaults needed for parsing are set.

pcre.recursion_limit is temporarily changed here. php default is 100,000 which is just too much for this type of parser. The reason for this code is the use of preg_* functions using pcre library. Some of the regex needed is just too much for php to handle, so by limiting this for regex we speed up the parser and allow it to safely lex/parse a string more here: http://stackoverflow.com/questions/7620910/regexp-in-preg-match-function-returning-browser-error

Parameters

mixed $input

postParse()

postParse(\WikiLingo\Parsed $parsed) : string

Where what has been parsed is then rendered

Parameters

\WikiLingo\Parsed $parsed

Returns

string

setInput()

setInput( $input)

Parameters

$input

lexerError()

lexerError( $str, \WikiLingo\LexerError $hash)

Parameters

$str
\WikiLingo\LexerError $hash

trace()

trace()

parserPerformAction()

parserPerformAction( $thisS,  $yy,  $yystate,  $s,  $o)

Parameters

$thisS
$yy
$yystate
$s
$o

parserLex()

parserLex()

input()

input()

unput()

unput( $ch)

Parameters

$ch

more()

more()

pastInput()

pastInput()

upcomingInput()

upcomingInput()

showPosition()

showPosition()

next()

next()

lexerLex()

lexerLex()

begin()

begin( $condition)

Parameters

$condition

popState()

popState()

currentRules()

currentRules()

LexerPerformAction()

LexerPerformAction( $avoidingNameCollisions,  $YY_START)

Parameters

$avoidingNameCollisions
$YY_START

addType()

addType( $type) : \WikiLingo\Number

Parameters

$type

Returns

\WikiLingo\Number

clearTypes()

clearTypes()

Clears all expression types

stackPlugin()

stackPlugin(String $name)

Stacks plugins for execution, since plugins can be called within each other.

Parameters

String $name

isContent()

isContent(array $skipTypes) : string

Detects if we are in a state that we can call the lexed grammer 'content'. Since the execution technique from the parser is inside-out, this helps us reverse the execution from outside-in in some cases.

Parameters

array $skipTypes

Returns

string —

true if content is current not parse-able

removeEOF()

removeEOF( $output)

Parameters

$output