Struct apollo_compiler::ast::Field
source · pub struct Field {
pub alias: Option<Name>,
pub name: Name,
pub arguments: Vec<Node<Argument>>,
pub directives: Directives,
pub selection_set: Vec<Selection>,
}
Fields§
§alias: Option<Name>
§name: Name
§arguments: Vec<Node<Argument>>
§directives: Directives
§selection_set: Vec<Selection>
Implementations§
source§impl Field
impl Field
sourcepub fn response_name(&self) -> &Name
pub fn response_name(&self) -> &Name
Get the name that will be used for this field selection in response formatting.
For example, in this operation, the response name is “sourceField”:
query GetField { sourceField }
But in this operation that uses an alias, the response name is “responseField”:
query GetField { responseField: sourceField }
Trait Implementations§
source§impl PartialEq for Field
impl PartialEq for Field
impl Eq for Field
impl StructuralEq for Field
impl StructuralPartialEq for Field
Auto Trait Implementations§
impl RefUnwindSafe for Field
impl Send for Field
impl Sync for Field
impl Unpin for Field
impl UnwindSafe for Field
Blanket Implementations§
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.