MediaWiki master
|
Inherited by MediaWiki\Parser\PPFrame_Hash.
Public Member Functions | |
cachedExpand ( $key, $root, $flags=0) | |
Expand a document tree node, caching the result on its parent with the given key. | |
expand ( $root, $flags=0) | |
Expand a document tree node. | |
getArgument ( $name) | |
Get an argument to this frame by name. | |
getArguments () | |
Returns all arguments of this frame. | |
getNamedArguments () | |
Returns all named arguments of this frame. | |
getNumberedArguments () | |
Returns all numbered arguments of this frame. | |
getTitle () | |
Get a title of frame. | |
getTTL () | |
Get the TTL of the frame's output. | |
implode ( $sep,... $params) | |
Implode with no flags specified. | |
implodeWithFlags ( $sep, $flags,... $params) | |
Implode with flags for expand() | |
isEmpty () | |
Returns true if there are no arguments in this frame. | |
isTemplate () | |
Return true if the frame is a template frame. | |
isVolatile () | |
Get the "volatile" flag. | |
loopCheck ( $title) | |
Returns true if the infinite loop check is OK, false if a loop is detected. | |
newChild ( $args=false, $title=false, $indexOffset=0) | |
Create a child frame. | |
setTTL ( $ttl) | |
Set the TTL of the output of this frame and all of its ancestors. | |
setVolatile ( $flag=true) | |
Set the "volatile" flag. | |
virtualBracketedImplode ( $start, $sep, $end,... $params) | |
Virtual implode with brackets. | |
virtualImplode ( $sep,... $params) | |
Makes an object that, when expand()ed, will be the same as one obtained with implode() | |
Public Attributes | |
const | NO_ARGS = 1 |
const | NO_IGNORE = 8 |
const | NO_TAGS = 32 |
const | NO_TEMPLATES = 2 |
const | PROCESS_NOWIKI = 64 |
const | RECOVER_COMMENTS = 16 |
const | RECOVER_ORIG |
const | STRIP_COMMENTS = 4 |
Definition at line 32 of file PPFrame.php.
MediaWiki\Parser\PPFrame::cachedExpand | ( | $key, | |
$root, | |||
$flags = 0 ) |
Expand a document tree node, caching the result on its parent with the given key.
string | int | $key | |
string | PPNode | $root | |
int | $flags |
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::expand | ( | $root, | |
$flags = 0 ) |
Expand a document tree node.
string | PPNode | $root | |
int | $flags |
Implemented in MediaWiki\Parser\PPFrame_Hash.
Referenced by MediaWiki\Parser\Parser\argSubstitution(), MediaWiki\Parser\Parser\braceSubstitution(), MediaWiki\Parser\Parser\callParserFunction(), and MediaWiki\Parser\Parser\extensionSubstitution().
MediaWiki\Parser\PPFrame::getArgument | ( | $name | ) |
Get an argument to this frame by name.
int | string | $name |
Implemented in MediaWiki\Parser\PPCustomFrame_Hash, MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
Referenced by MediaWiki\Parser\Parser\argSubstitution().
MediaWiki\Parser\PPFrame::getArguments | ( | ) |
Returns all arguments of this frame.
Implemented in MediaWiki\Parser\PPCustomFrame_Hash, MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::getNamedArguments | ( | ) |
Returns all named arguments of this frame.
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::getNumberedArguments | ( | ) |
Returns all numbered arguments of this frame.
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::getTitle | ( | ) |
MediaWiki\Parser\PPFrame::getTTL | ( | ) |
Get the TTL of the frame's output.
This is the maximum amount of time, in seconds, that this frame's output should be cached for. A value of null indicates that no maximum has been specified.
Note that this TTL only applies to caching frames as parts of pages. It is not relevant to caching the entire rendered output of a page.
Implemented in MediaWiki\Parser\PPFrame_Hash.
MediaWiki\Parser\PPFrame::implode | ( | $sep, | |
$params ) |
Implode with no flags specified.
string | $sep | |
string|PPNode | ...$params |
Implemented in MediaWiki\Parser\PPFrame_Hash.
MediaWiki\Parser\PPFrame::implodeWithFlags | ( | $sep, | |
$flags, | |||
$params ) |
Implode with flags for expand()
string | $sep | |
int | $flags | |
string|PPNode | ...$params |
Implemented in MediaWiki\Parser\PPFrame_Hash.
MediaWiki\Parser\PPFrame::isEmpty | ( | ) |
Returns true if there are no arguments in this frame.
Implemented in MediaWiki\Parser\PPCustomFrame_Hash, MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::isTemplate | ( | ) |
Return true if the frame is a template frame.
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
Referenced by MediaWiki\Parser\Parser\argSubstitution().
MediaWiki\Parser\PPFrame::isVolatile | ( | ) |
Get the "volatile" flag.
Callers should avoid caching the result of an expansion if it has the volatile flag set.
Implemented in MediaWiki\Parser\PPFrame_Hash.
MediaWiki\Parser\PPFrame::loopCheck | ( | $title | ) |
Returns true if the infinite loop check is OK, false if a loop is detected.
Title | $title |
Implemented in MediaWiki\Parser\PPFrame_Hash.
Referenced by MediaWiki\Parser\Parser\braceSubstitution().
MediaWiki\Parser\PPFrame::newChild | ( | $args = false, | |
$title = false, | |||
$indexOffset = 0 ) |
Create a child frame.
PPNode[] | false | $args | |
Title | false | $title | |
int | $indexOffset | A number subtracted from the index attributes of the arguments |
Implemented in MediaWiki\Parser\PPFrame_Hash.
Referenced by MediaWiki\Parser\Parser\braceSubstitution().
MediaWiki\Parser\PPFrame::setTTL | ( | $ttl | ) |
Set the TTL of the output of this frame and all of its ancestors.
Has no effect if the new TTL is greater than the one already set. Note that it is the caller's responsibility to change the cache expiry of the page as a whole, if such behavior is desired.
int | $ttl |
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::setVolatile | ( | $flag = true | ) |
Set the "volatile" flag.
Note that this is somewhat of a "hack" in order to make extensions with side effects (such as Cite) work with the PHP parser. New extensions should be written in a way that they do not need this function, because other parsers (such as Parsoid) are not guaranteed to respect it, and it may be removed in the future.
bool | $flag |
Implemented in MediaWiki\Parser\PPFrame_Hash, and MediaWiki\Parser\PPTemplateFrame_Hash.
MediaWiki\Parser\PPFrame::virtualBracketedImplode | ( | $start, | |
$sep, | |||
$end, | |||
$params ) |
Virtual implode with brackets.
string | $start | |
string | $sep | |
string | $end | |
string|PPNode | ...$params |
Implemented in MediaWiki\Parser\PPFrame_Hash.
Referenced by MediaWiki\Parser\Parser\argSubstitution(), and MediaWiki\Parser\Parser\braceSubstitution().
MediaWiki\Parser\PPFrame::virtualImplode | ( | $sep, | |
$params ) |
Makes an object that, when expand()ed, will be the same as one obtained with implode()
string | $sep | |
string|PPNode | ...$params |
Implemented in MediaWiki\Parser\PPFrame_Hash.
const MediaWiki\Parser\PPFrame::NO_ARGS = 1 |
Definition at line 33 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand(), and MediaWiki\Parser\Parser\getPreloadText().
const MediaWiki\Parser\PPFrame::NO_IGNORE = 8 |
Definition at line 36 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand().
const MediaWiki\Parser\PPFrame::NO_TAGS = 32 |
Definition at line 38 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand().
const MediaWiki\Parser\PPFrame::NO_TEMPLATES = 2 |
Definition at line 34 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand(), and MediaWiki\Parser\Parser\getPreloadText().
const MediaWiki\Parser\PPFrame::PROCESS_NOWIKI = 64 |
Definition at line 39 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand().
const MediaWiki\Parser\PPFrame::RECOVER_COMMENTS = 16 |
Definition at line 37 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand().
const MediaWiki\Parser\PPFrame::RECOVER_ORIG |
Definition at line 41 of file PPFrame.php.
const MediaWiki\Parser\PPFrame::STRIP_COMMENTS = 4 |
Definition at line 35 of file PPFrame.php.
Referenced by MediaWiki\Parser\PPFrame_Hash\expand(), MediaWiki\Parser\PPTemplateFrame_Hash\getNamedArgument(), MediaWiki\Parser\PPTemplateFrame_Hash\getNumberedArgument(), and MediaWiki\Parser\PPFrame_Hash\newChild().