Engine Class
The parser engine does the actual string substitutions
Item Index
Methods
- asBoolean static
- checkBacktrackLimit static
- lookupValue
- parse static
Methods
asBoolean
-
str
Global functions to check for a string-based boolean
Parameters:
-
str
MixedThe value to check as Boolean
Returns:
A boolean value
checkBacktrackLimit
-
string
The default backtrack limit for preg expressions is 100KB, we may have pages which ar larger than 100,000, and need to increase the pcre.backtrack_limit
Parameters:
-
string
StringThe string to limit test
lookupValue
-
context
-
name
Get the nested value for a dot-syntax array/object lookup
For instance, getNextVar($substitutions, 'event.name')
Parameters:
Returns:
The value of the lookup
parse
-
content
-
substitutions
-
[profiler=null]
Prepare the site content to be displayed This does all of the data substitutions and url fixes. The order of operations is to do the templates, loops, if blocks, then individual substitutions.
Parameters:
-
content
StringThe content data
-
substitutions
DictionaryThe substitutions key => value replaces in template
-
[profiler=null]
Profiler optionalOptional profiler usage to track performance
Returns:
The parsed template