CSS selector parser.

This component is a port of the Python cssselect library,
which is copyright Ian Bicking, @see https://github.com/SimonSapin/cssselect.

Cloneable Instantiable
Methods
public __construct ( ? Symfony\Component\CssSelector\Parser\Tokenizer\Tokenizer $tokenizer = NULL )
public parse ( string $source ) : array
 
public static parseSeries ( array $tokens ) : array
 

Parses the arguments for ":nth-child()" and friends.

Properties
private $tokenizer
Methods
private parseAttributeNode ( Symfony\Component\CssSelector\Node\NodeInterface $selector , Symfony\Component\CssSelector\Parser\TokenStream $stream ) : Symfony\Component\CssSelector\Node\AttributeNode
private parseElementNode ( Symfony\Component\CssSelector\Parser\TokenStream $stream ) : Symfony\Component\CssSelector\Node\ElementNode
private parserSelectorNode ( Symfony\Component\CssSelector\Parser\TokenStream $stream ) : Symfony\Component\CssSelector\Node\SelectorNode
private parseSelectorList ( Symfony\Component\CssSelector\Parser\TokenStream $stream ) : array
private parseSimpleSelector ( Symfony\Component\CssSelector\Parser\TokenStream $stream , bool $insideNegation = false ) : array
 

Parses next simple node (hash, class, pseudo, negation).

  • throws SyntaxErrorException
Methods
public static parseSeries ( array $tokens ) : array
 

Parses the arguments for ":nth-child()" and friends.

© 2022 Bruce Wells
Search Namespaces \ Classes
Configuration