MediaWiki  REL1_20
Preprocessor.php
Go to the documentation of this file.
00001 <?php
00027 interface Preprocessor {
00033         function __construct( $parser );
00034 
00040         function newFrame();
00041 
00049         function newCustomFrame( $args );
00050 
00056         function newPartNodeArray( $values );
00057 
00066         function preprocessToObj( $text, $flags = 0 );
00067 }
00068 
00072 interface PPFrame {
00073         const NO_ARGS = 1;
00074         const NO_TEMPLATES = 2;
00075         const STRIP_COMMENTS = 4;
00076         const NO_IGNORE = 8;
00077         const RECOVER_COMMENTS = 16;
00078 
00079         const RECOVER_ORIG = 27; // = 1|2|8|16 no constant expression support in PHP yet
00080 
00082         const SUPPORTS_INDEX_OFFSET = 1;
00083 
00093         function newChild( $args = false, $title = false, $indexOffset = 0 );
00094 
00098         function expand( $root, $flags = 0 );
00099 
00103         function implodeWithFlags( $sep, $flags /*, ... */ );
00104 
00108         function implode( $sep /*, ... */ );
00109 
00114         function virtualImplode( $sep /*, ... */ );
00115 
00119         function virtualBracketedImplode( $start, $sep, $end /*, ... */ );
00120 
00126         function isEmpty();
00127 
00131         function getArguments();
00132 
00136         function getNumberedArguments();
00137 
00141         function getNamedArguments();
00142 
00146         function getArgument( $name );
00147 
00155         function loopCheck( $title );
00156 
00160         function isTemplate();
00161 
00167         function getTitle();
00168 }
00169 
00183 interface PPNode {
00188         function getChildren();
00189 
00195         function getFirstChild();
00196 
00200         function getNextSibling();
00201 
00206         function getChildrenOfType( $type );
00207 
00208 
00212         function getLength();
00213 
00217         function item( $i );
00218 
00231         function getName();
00232 
00239         function splitArg();
00240 
00245         function splitExt();
00246 
00250         function splitHeading();
00251 }