AttributeMatchingExtension
class AttributeMatchingExtension extends AbstractExtension
XPath expression translator attribute extension.
This component is a port of the Python cssselect library, which is copyright Ian Bicking, see https://github.com/SimonSapin/cssselect.
Methods
callable[] | getNodeTranslators() Returns node translators. | from AbstractExtension |
callable[] | getCombinationTranslators() Returns combination translators. | from AbstractExtension |
callable[] | getFunctionTranslators() Returns function translators. | from AbstractExtension |
callable[] | getPseudoClassTranslators() Returns pseudo-class translators. | from AbstractExtension |
callable[] | getAttributeMatchingTranslators() Returns attribute operation translators. | |
XPathExpr | translateExists(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateEquals(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateIncludes(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateDashMatch(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translatePrefixMatch(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateSuffixMatch(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateSubstringMatch(XPathExpr $xpath, string $attribute, string|null $value) | |
XPathExpr | translateDifferent(XPathExpr $xpath, string $attribute, string|null $value) | |
string | getName() Returns extension name. | |
Details
callable[]
getNodeTranslators()
Returns node translators.
These callables will receive the node as first argument and the translator as second argument.
Return Value
callable[]
getCombinationTranslators()
Returns combination translators.
Return Value
callable[]
getFunctionTranslators()
Returns function translators.
Return Value
callable[]
getPseudoClassTranslators()
Returns pseudo-class translators.
Return Value
callable[]
getAttributeMatchingTranslators()
Returns attribute operation translators.
Return Value
XPathExpr
translateExists(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateEquals(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateIncludes(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateDashMatch(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translatePrefixMatch(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateSuffixMatch(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateSubstringMatch(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
XPathExpr
translateDifferent(XPathExpr $xpath, string $attribute, string|null $value)
Parameters
XPathExpr | $xpath | |
string | $attribute | |
string|null | $value | |
Return Value
string
getName()
Returns extension name.
Return Value