Enum scraper_main::Node
source · pub enum Node {
Root(Rc<Node>),
DocType(Weak<Node>),
Element(Weak<Node>),
Attribute(Attribute),
Text(Weak<Node>),
Comment(Weak<Node>),
ProcessingInstruction(Weak<Node>),
Namespace(Weak<Node>),
}Variants
Root(Rc<Node>)
DocType(Weak<Node>)
Element(Weak<Node>)
Attribute(Attribute)
Text(Weak<Node>)
Comment(Weak<Node>)
ProcessingInstruction(Weak<Node>)
Namespace(Weak<Node>)
Implementations
sourceimpl Node
impl Node
pub fn enum_name(&self) -> String
pub fn is_root(&self) -> bool
pub fn is_namespace(&self) -> bool
pub fn is_element(&self) -> bool
pub fn is_attribute(&self) -> bool
pub fn is_text(&self) -> bool
pub fn is_comment(&self) -> bool
pub fn is_processing_instruction(&self) -> bool
pub fn get_string_value(&self) -> Result<String, Error>
pub fn value(&self) -> Result<Value, Error>
pub fn as_simple_html(&self) -> Option<String>
pub fn attribute(&self) -> Option<&Attribute>
pub fn parent(&self) -> Option<Node>
pub fn children(&self) -> Vec<Node, Global>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
A: Allocator,
pub fn get_child(&self, index: usize) -> Option<Node>
pub fn name(&self) -> Option<QualName>
pub fn target(&self) -> Option<String>
pub fn prefix(&self) -> String
pub fn inner_weak(&self) -> Option<&Weak<Node>>
pub fn evaluate_from<S>(
&'a self,
search: S,
doc: &'a Document
) -> Result<ProduceIter<'a>, Error>where
S: Into<String>,
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Node
impl !Send for Node
impl !Sync for Node
impl Unpin for Node
impl !UnwindSafe for Node
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more