Trait html5ever_ext::Selectable [] [src]

pub trait Selectable {
    fn find_all_matching_child_nodes_depth_first_including_this_one<MatchUser: FnMut(&Rc<Node>) -> bool>(
        &self,
        selector: &OurSelector,
        match_user: &mut MatchUser
    ) -> bool;
fn find_all_matching_child_nodes_depth_first_excluding_this_one<MatchUser: FnMut(&Rc<Node>) -> bool>(
        &self,
        selector: &OurSelector,
        match_user: &mut MatchUser
    ) -> bool;
fn matches(&self, selector: &OurSelector) -> bool; }

This trait adds methods for finding DOM nodes matching a CSS selector

Required Methods

Recursively find element nodes that match this selector. Return true from MatchUser to abort early. The result of this function is true if MatchUser aborted early, or false otherwise.

Recursively find element nodes that match this selector. Return true from MatchUser to abort early. The result of this function is true if MatchUser aborted early, or false otherwise.

Returns whether this element matches this selector. For the RcDom and &'a RcDom, is currently always false.

Implementations on Foreign Types

impl<'a> Selectable for &'a [RcDom]
[src]

Use this to match a list of HTML documents.

[src]

[src]

[src]

impl<'a> Selectable for Rc<Node>
[src]

[src]

[src]

[src]

impl Selectable for RefCell<Vec<Rc<Node>>>
[src]

Use this to match on the children of a Rc, eg node.children.matches()

[src]

[src]

[src]

Implementors