pub struct QueryField {
pub name: String,
pub args: HashMap<String, usize>,
pub children: Vec<QueryField>,
}Expand description
A flat (non-tree) representation of a GraphQL field selection.
Fields§
§name: StringName of the selected field.
args: HashMap<String, usize>Numeric arguments for multiplier evaluation.
children: Vec<QueryField>Nested selections.
Implementations§
Source§impl QueryField
impl QueryField
Sourcepub fn with_arg(self, key: impl Into<String>, val: usize) -> Self
pub fn with_arg(self, key: impl Into<String>, val: usize) -> Self
Add a numeric argument (builder).
Sourcepub fn with_child(self, child: QueryField) -> Self
pub fn with_child(self, child: QueryField) -> Self
Add a child field (builder).
Trait Implementations§
Source§impl Clone for QueryField
impl Clone for QueryField
Auto Trait Implementations§
impl Freeze for QueryField
impl RefUnwindSafe for QueryField
impl Send for QueryField
impl Sync for QueryField
impl Unpin for QueryField
impl UnsafeUnpin for QueryField
impl UnwindSafe for QueryField
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more