pub struct OperationDefinition<'a> {
pub operation: OperationKind,
pub name: Option<NamedType<'a>>,
pub variable_definitions: VariableDefinitions<'a>,
pub directives: Directives<'a>,
pub selection_set: SelectionSet<'a>,
}
Expand description
AST Node for an Operation Definition, which defines the entrypoint for GraphQL’s execution.
Fields§
§operation: OperationKind
The kind of operation that this definition specifies
name: Option<NamedType<'a>>
§variable_definitions: VariableDefinitions<'a>
A list of variables that the operation defines and accepts during execution.
When an
Operation Definition defines no variables this may be an empty list, as can be checked
using Directives::is_empty
.
directives: Directives<'a>
Directives that are annotating this Operation Definition.
When no Directives are present, this will be an empty
list, as can be checked using Directives::is_empty
.
See: Directives
selection_set: SelectionSet<'a>
A sub-Selection Set that is applied when this Operation Definition is executed to the root type of the specified kind of operation. See: SelectionSet
Trait Implementations§
Source§impl<'a> Clone for OperationDefinition<'a>
impl<'a> Clone for OperationDefinition<'a>
Source§fn clone(&self) -> OperationDefinition<'a>
fn clone(&self) -> OperationDefinition<'a>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<'a> Debug for OperationDefinition<'a>
impl<'a> Debug for OperationDefinition<'a>
Source§impl<'a> From<OperationDefinition<'a>> for Definition<'a>
impl<'a> From<OperationDefinition<'a>> for Definition<'a>
Source§fn from(x: OperationDefinition<'a>) -> Self
fn from(x: OperationDefinition<'a>) -> Self
Converts to this type from the input type.
Source§impl<'a> PartialEq for OperationDefinition<'a>
impl<'a> PartialEq for OperationDefinition<'a>
Source§impl<'a> PrintNode for OperationDefinition<'a>
impl<'a> PrintNode for OperationDefinition<'a>
Source§impl<'arena> WithDirectives<'arena> for OperationDefinition<'arena>
impl<'arena> WithDirectives<'arena> for OperationDefinition<'arena>
fn directives(&self) -> &Directives<'arena>
impl<'a> StructuralPartialEq for OperationDefinition<'a>
Auto Trait Implementations§
impl<'a> Freeze for OperationDefinition<'a>
impl<'a> !RefUnwindSafe for OperationDefinition<'a>
impl<'a> !Send for OperationDefinition<'a>
impl<'a> !Sync for OperationDefinition<'a>
impl<'a> Unpin for OperationDefinition<'a>
impl<'a> !UnwindSafe for OperationDefinition<'a>
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