[−][src]Struct pest_consume::Node
A node of the parse tree.
Methods
impl<'i, R: RuleType, D> Node<'i, R, D>
[src]
pub fn as_str(&self) -> &'i str
[src]
pub fn as_span(&self) -> Span<'i>
[src]
pub fn as_rule(&self) -> R
[src]
pub fn into_children(self) -> Nodes<'i, R, D>
[src]
Returns an iterator over the children of this node
pub fn children(&self) -> Nodes<'i, R, D> where
D: Clone,
[src]
D: Clone,
Returns an iterator over the children of this node
pub fn error<S: ToString>(&self, message: S) -> Error<R>
[src]
Create an error that points to the span of the node.
pub fn user_data(&self) -> &D
[src]
pub fn into_user_data(self) -> D
[src]
pub fn as_pair(&self) -> &Pair<'i, R>
[src]
pub fn into_pair(self) -> Pair<'i, R>
[src]
Trait Implementations
impl<'input, Rule: Clone + RuleType, Data: Clone> Clone for Node<'input, Rule, Data>
[src]
impl<'input, Rule: Debug + RuleType, Data: Debug> Debug for Node<'input, Rule, Data>
[src]
impl<'i, R: RuleType, D> Display for Node<'i, R, D>
[src]
impl<'input, Rule: Eq + RuleType, Data: Eq> Eq for Node<'input, Rule, Data>
[src]
impl<'input, Rule: Hash + RuleType, Data: Hash> Hash for Node<'input, Rule, Data>
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl<'input, Rule: PartialEq + RuleType, Data: PartialEq> PartialEq<Node<'input, Rule, Data>> for Node<'input, Rule, Data>
[src]
fn eq(&self, other: &Node<'input, Rule, Data>) -> bool
[src]
fn ne(&self, other: &Node<'input, Rule, Data>) -> bool
[src]
impl<'input, Rule: RuleType, Data> StructuralEq for Node<'input, Rule, Data>
[src]
impl<'input, Rule: RuleType, Data> StructuralPartialEq for Node<'input, Rule, Data>
[src]
Auto Trait Implementations
impl<'input, Rule, Data> !RefUnwindSafe for Node<'input, Rule, Data>
impl<'input, Rule, Data> !Send for Node<'input, Rule, Data>
impl<'input, Rule, Data> !Sync for Node<'input, Rule, Data>
impl<'input, Rule, Data> Unpin for Node<'input, Rule, Data> where
Data: Unpin,
Data: Unpin,
impl<'input, Rule, Data> UnwindSafe for Node<'input, Rule, Data> where
Data: UnwindSafe,
Rule: RefUnwindSafe,
Data: UnwindSafe,
Rule: RefUnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,