Struct select::document::Document [] [src]

pub struct Document {
    pub nodes: Vec<Raw>,
}

An HTML document.

Fields

nodes: Vec<Raw>

Methods

impl Document
[src]

fn from_str(str: &str) -> Document

Parses the given &str into a Document.

fn find<'a, P: Predicate>(&'a self, p: P) -> Selection<'a>

Returns a Selection containing nodes passing the given predicate p.

fn nth(&self, n: usize) -> Node

Returns the nth node of the document as a Node, indexed from 0.

Panics

Panics if n is not less than the number of nodes in self.

Trait Implementations

impl PartialEq for Document
[src]

fn eq(&self, __arg_0: &Document) -> bool

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, __arg_0: &Document) -> bool

This method tests for !=.

impl Debug for Document
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Clone for Document
[src]

fn clone(&self) -> Document

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