pub enum DirectiveResult {
Include,
Skip,
Transform(Value),
Error(String),
}Expand description
Result of custom directive evaluation.
Determines how a field should be handled after directive processing.
Variants§
Include
Include the field in the response (default behavior).
Skip
Skip the field entirely (like @skip(if: true)).
Transform(Value)
Transform the field value before returning. The transformation is applied after field resolution.
Error(String)
Directive encountered an error that should be reported.
Trait Implementations§
Source§impl Clone for DirectiveResult
impl Clone for DirectiveResult
Source§fn clone(&self) -> DirectiveResult
fn clone(&self) -> DirectiveResult
Returns a duplicate 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 Debug for DirectiveResult
impl Debug for DirectiveResult
Source§impl Default for DirectiveResult
impl Default for DirectiveResult
Source§fn default() -> DirectiveResult
fn default() -> DirectiveResult
Returns the “default value” for a type. Read more
Source§impl PartialEq for DirectiveResult
impl PartialEq for DirectiveResult
impl StructuralPartialEq for DirectiveResult
Auto Trait Implementations§
impl Freeze for DirectiveResult
impl RefUnwindSafe for DirectiveResult
impl Send for DirectiveResult
impl Sync for DirectiveResult
impl Unpin for DirectiveResult
impl UnsafeUnpin for DirectiveResult
impl UnwindSafe for DirectiveResult
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