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 line 27
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 line 35
callable[] getCombinationTranslators()

Returns combination translators.

Return Value

callable[]

at line line 57
callable[] getFunctionTranslators()

Returns function translators.

Return Value

callable[]

at line line 40
callable[] getPseudoClassTranslators()

Returns pseudo-class translators.

Return Value

callable[]

in AbstractExtension at line line 59
callable[] getAttributeMatchingTranslators()

Returns attribute operation translators.

Return Value

callable[]

at line line 29
__construct(Translator $translator)

Parameters

Translator $translator

at line line 67
XPathExpr translateChecked(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 87
XPathExpr translateDisabled(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 116
XPathExpr translateEnabled(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

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

Parameters

XPathExpr $xpath
FunctionNode $function

Return Value

XPathExpr

Exceptions

ExpressionErrorException

at line line 178
XPathExpr translateSelected(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 186
XPathExpr translateInvalid(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 194
XPathExpr translateHover(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 202
XPathExpr translateVisited(XPathExpr $xpath)

Parameters

XPathExpr $xpath

Return Value

XPathExpr

at line line 210
string getName()

Returns extension name.

Return Value

string