The consumer (e.g. XmlDb::getNodeIdsByXpath) receives pre-parsed objects carrying all condition data, avoiding repeated parser calls inside the element iteration loop. SQL assembly is done in the caller so the XpathParser remains SQL-independent and potentially reusable.
Definition at line 15 of file XpathParser.php.
Public Member Functions | |
| parseXpathElements (string $xpath) | |
| parsePosition ($condition) | |
| parseAttributes ($condition) | |
| translateName ($ns, $name) | |
| getConditionOperator ($ns, $name) | |
| getConditionAttributes ($conditionString, $strings) | |
| cleanOperator ($operator) | |
Protected Member Functions | |
| removeLiteralStrings ($text, &$strings) | |
| cleanOperator | ( | $operator | ) |
| string | $operator | xpath operator string |
| XmlDbException | if operator is invalid |
Definition at line 168 of file XpathParser.php.
| getConditionAttributes | ( | $conditionString, | |
| $strings ) |
| string | $conditionString | cleaned condition string |
| array | $strings | reference array for literal strings |
Definition at line 103 of file XpathParser.php.
| getConditionOperator | ( | $ns, | |
| $name ) |
| string | $ns | namespace |
| string | $name | node name |
Definition at line 89 of file XpathParser.php.
| parseAttributes | ( | $condition | ) |
| string | $condition | condition string to parse |
Definition at line 62 of file XpathParser.php.
| parsePosition | ( | $condition | ) |
| string | $condition | condition string from xpath |
Definition at line 43 of file XpathParser.php.
| parseXpathElements | ( | string | $xpath | ) |
| string | $xpath | XPath string to parse |
Definition at line 21 of file XpathParser.php.
|
protected |
| string | $text | input text |
| array | $strings | reference array to populate with extracted literal strings |
Definition at line 142 of file XpathParser.php.
| translateName | ( | $ns, | |
| $name ) |
| string | $ns | namespace |
| string | $name | node name |
Definition at line 78 of file XpathParser.php.