Struct scraper::selector::Selector
[−]
[src]
pub struct Selector { pub selectors: Vec<Selector<Simple>>, }
Wrapper around CSS selectors.
Represents a "selector group", i.e. a comma-separated list of selectors.
Fields
selectors: Vec<Selector<Simple>>
The CSS selectors.
Methods
impl Selector
[src]
fn parse(selectors: &str) -> Result<Self, ()>
Parses a CSS selector group.
No meaningful error can be returned here, due to a limitation of the selectors
and
cssparser
crates.
fn matches(&self, element: &ElementRef) -> bool
Returns true if the element matches this selector.
Trait Implementations
impl Debug for Selector
[src]
impl Clone for Selector
[src]
fn clone(&self) -> Selector
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more