Skip to main content

Token

Enum Token 

Source
pub enum Token {
Show 46 variants Name(String), Star, Dot, DotDot, At, DoubleColon, Slash, DoubleSlash, Pipe, Plus, Minus, Eq, Ne, Lt, Gt, Le, Ge, Multiply, Or, And, Mod, Div, Ancestor, AncestorOrSelf, Attribute, Child, Descendant, DescendantOrSelf, Following, FollowingSibling, Namespace, Parent, Preceding, PrecedingSibling, Self_, StringLiteral(String), NumberLiteral(f64), LParen, RParen, LBracket, RBracket, LBrace, RBrace, Comma, Dollar, Eof,
}

Variants§

§

Name(String)

Name (NCName or QName)

§

Star

* wildcard

§

Dot

. (self)

§

DotDot

.. (parent)

§

At

@ (attribute axis)

§

DoubleColon

:: (axis separator)

§

Slash

/

§

DoubleSlash

//

§

Pipe

|

§

Plus

+

§

Minus

-

§

Eq

=

§

Ne

!=

§

Lt

<

§

Gt

>

§

Le

<=

§

Ge

>=

§

Multiply

* (multiplication operator, distinct from wildcard)

§

Or

or

§

And

and

§

Mod

mod

§

Div

div

§

Ancestor

ancestor

§

AncestorOrSelf

ancestor-or-self

§

Attribute

attribute

§

Child

child

§

Descendant

descendant

§

DescendantOrSelf

descendant-or-self

§

Following

following

§

FollowingSibling

following-sibling

§

Namespace

namespace

§

Parent

parent

§

Preceding

preceding

§

PrecedingSibling

preceding-sibling

§

Self_

self

§

StringLiteral(String)

String literal (without quotes)

§

NumberLiteral(f64)

Numeric literal

§

LParen

§

RParen

§

LBracket

§

RBracket

§

LBrace

§

RBrace

§

Comma

§

Dollar

$ (variable reference)

§

Eof

End of expression

Trait Implementations§

Source§

impl Clone for Token

Source§

fn clone(&self) -> Token

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Token

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for Token

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for Token

Source§

fn eq(&self, other: &Token) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Token

Auto Trait Implementations§

§

impl Freeze for Token

§

impl RefUnwindSafe for Token

§

impl Send for Token

§

impl Sync for Token

§

impl Unpin for Token

§

impl UnsafeUnpin for Token

§

impl UnwindSafe for Token

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.