class HtmlExtension extends AbstractExtension

XPath expression translator HTML 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.

callable[]
getCombinationTranslators()

Returns combination translators.

callable[]
getFunctionTranslators()

Returns function translators.

callable[]
getPseudoClassTranslators()

Returns pseudo-class translators.

callable[]
getAttributeMatchingTranslators()

Returns attribute operation translators.

__construct(Translator $translator)

No description

translateChecked(XPathExpr $xpath)

No description

translateLink(XPathExpr $xpath)

No description

translateDisabled(XPathExpr $xpath)

No description

translateEnabled(XPathExpr $xpath)

No description

translateLang(XPathExpr $xpath, FunctionNode $function)

No description

translateSelected(XPathExpr $xpath)

No description

translateInvalid(XPathExpr $xpath)

No description

translateHover(XPathExpr $xpath)

No description

translateVisited(XPathExpr $xpath)

No description

string
getName()

Returns extension name.

Details

in AbstractExtension at line 29
callable[] getNodeTranslators()

Returns node translators.

These callables will receive the node as first argument and the translator as second argument.

Return Value

callable[]

in AbstractExtension at line 37
callable[] getCombinationTranslators()

Returns combination translators.

Return Value

callable[]

at line 59
callable[] getFunctionTranslators()

Returns function translators.

Return Value

callable[]

at line 42
callable[] getPseudoClassTranslators()

Returns pseudo-class translators.

Return Value

callable[]

in AbstractExtension at line 61
callable[] getAttributeMatchingTranslators()

Returns attribute operation translators.

Return Value

callable[]

at line 31
__construct(Translator $translator)

Parameters

Translator $translator

at line 69
XPathExpr translateChecked(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 89
XPathExpr translateDisabled(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 118
XPathExpr translateEnabled(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 156
XPathExpr translateLang(XPathExpr $xpath, FunctionNode $function)

Parameters

XPathExpr $xpath
FunctionNode $function

Return Value

XPathExpr

Exceptions

ExpressionErrorException

at line 177
XPathExpr translateSelected(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 185
XPathExpr translateInvalid(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 193
XPathExpr translateHover(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 201
XPathExpr translateVisited(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line 209
string getName()

Returns extension name.

Return Value

string