Struct juniper::parser::Spanning
[−]
[src]
pub struct Spanning<T: Debug> { pub item: T, pub start: SourcePosition, pub end: SourcePosition, }
Data structure used to wrap items with start and end markers in the input source
A "span" is a range of characters in the input source, starting at the
character pointed by the start
field and ending just before the end
marker.
Fields
item: T
The wrapped item
start: SourcePosition
Start position of the item
end: SourcePosition
End position of the item
This points to the first source position after the wrapped item.
Methods
impl<T: Debug> Spanning<T>
[src]
Trait Implementations
impl<T: Debug + Debug> Debug for Spanning<T>
[src]
impl<T> Clone for Spanning<T> where T: Clone + Debug
[src]
fn clone(&self) -> Self
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
impl<T> PartialEq for Spanning<T> where T: PartialEq + Debug
[src]
fn eq(&self, other: &Self) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0
This method tests for !=
.
impl<T> Eq for Spanning<T> where T: Eq + Debug
[src]
impl<T> Hash for Spanning<T> where T: Hash + Debug
[src]
fn hash<H: Hasher>(&self, state: &mut H)
Feeds this value into the state given, updating the hasher as necessary.
fn hash_slice<H>(data: &[Self], state: &mut H) where H: Hasher
1.3.0
Feeds a slice of this type into the state provided.