All parsing logic (condition, position, attributes) is encapsulated in the constructor so that callers (e.g. XmlDb::getNodeIdsByXpath) never need to call XpathParser helpers again — they only read pre-computed properties.
The parser itself remains SQL-agnostic; the caller is responsible for assembling SQL fragments from the pre-parsed data.
Definition at line 17 of file XpathElement.php.
Public Member Functions | |
| __construct (string $divider, string $namespace, string $name, string $condition) | |
Data Fields | |
| readonly string | $divider |
| readonly string | $namespace |
| readonly string | $name |
| readonly string | $condition |
| readonly mixed | $position |
| readonly mixed | $attributes |
| readonly bool | $attributesValid |
Protected Member Functions | |
| parsePosition ($condition) | |
| getConditionAttributes ($conditionString, $strings) | |
| removeLiteralStrings ($text, &$strings) | |
| __construct | ( | string | $divider, |
| string | $namespace, | ||
| string | $name, | ||
| string | $condition ) |
| string | $divider | divider character |
| string | $namespace | namespace prefix |
| string | $name | node name |
| string | $condition | condition string |
Definition at line 36 of file XpathElement.php.
|
protected |
| string | $conditionString | cleaned condition string |
| array | $strings | extracted literal strings |
| XmlDbException | on invalid syntax |
Definition at line 96 of file XpathElement.php.
|
protected |
| string | $condition | condition string |
Definition at line 75 of file XpathElement.php.
|
protected |
| string | $text | input text |
| array | &$strings | reference to populate with extracted literals |
Definition at line 132 of file XpathElement.php.
| readonly mixed $attributes |
Definition at line 27 of file XpathElement.php.
| readonly bool $attributesValid |
Definition at line 28 of file XpathElement.php.
| readonly string $condition |
Definition at line 23 of file XpathElement.php.
| readonly string $divider |
Definition at line 20 of file XpathElement.php.
| readonly string $name |
Definition at line 22 of file XpathElement.php.
| readonly string $namespace |
Definition at line 21 of file XpathElement.php.
| readonly mixed $position |
Definition at line 26 of file XpathElement.php.