pub fn parent_node(&self) -> Result<&Node<RequestCtx>, Error> {
        if let Object::Node(n) = self.parent {
            Ok(n)
        } else {
            Err(Error::TypeNotExpected { details: None })
        }
    }
/// Returns the parent GraphQL object of the field being resolved as a [`Node`]
///
/// # Errors
///
/// Returns an [`Error`] of variant [`TypeNotExpected`] if the parent object is not a node
///
/// [`Error`]: ../../error/enum.Error.html
/// [`TypeNotExpected`]: ../../error/enum.Error.html#variant.TypeNotExpected
///
/// # Examples
///
/// ```rust, no_run
/// # use warpgrapher::engine::resolvers::{ResolverFacade, ExecutionResult};
/// # use warpgrapher::juniper::BoxFuture;
/// # use warpgrapher::juniper::{GraphQLType, GraphQLValue};
///
/// fn custom_resolve(facade: ResolverFacade<()>) -> BoxFuture<ExecutionResult> {
///     Box::pin(async move {
///         let parent_node = facade.parent_node()?;
///         println!("Parent type: {:#?}",
///             parent_node.concrete_type_name(facade.executor().context(), facade.info()));
///
///         facade.resolve_null()
///     })
/// }
/// ```
Returns the parent GraphQL object of the field being resolved as a [`Node`]
Returns the parent GraphQL object of the field being resolved as a [ ` Node ` ]
pub fn parent_node(&self) -> Result<&Node<RequestCtx>, Error> {
        if let Object::Node(n) = self.parent {
            Ok(n)
        } else {
            Err(Error::TypeNotExpected { details: None })
        }
    }
pub fn parent_node ( & self ) -> Result < & Node < RequestCtx > , Error > { if let Object :: Node ( n ) = self . parent { Ok ( n ) } else { Err ( Error :: TypeNotExpected { details : None } ) } }
Returns the parent GraphQL object of the field being resolved as a [`Node`]
Returns the parent GraphQL object of the field being resolved as a [ ` Node ` ]
&self
&self
errors
Returns an [`Error`] of variant [`TypeNotExpected`] if the parent object is not a node

[`Error`]: ../../error/enum.Error.html
[`TypeNotExpected`]: ../../error/enum.Error.html#variant.TypeNotExpected
Returns an [ ` Error ` ] of variant [ ` TypeNotExpected ` ] if the parent object is not a node [ ` Error ` ] : .. / .. / error / enum . Error . html [ ` TypeNotExpected ` ] : .. / .. / error / enum . Error . html#variant . TypeNotExpected
examples
None
use warpgrapher::engine::resolvers::{resolverfacade, executionresult};
None
use warpgrapher::juniper::boxfuture;
None
use warpgrapher::juniper::{graphqltype, graphqlvalue};
fn custom_resolve(facade: ResolverFacade<()>) -> BoxFuture {
Box::pin(async move {
let parent_node = facade.parent_node()?;
println!("Parent type: {:#?}",
parent_node.concrete_type_name(facade.executor().context(), facade.info())).


fn custom_resolve ( facade : ResolverFacade< () > ) - > BoxFuture { Box :: pin ( async move { let parent_node = facade . parent_node () ? ; println! ( " Parent type : { : #? } " parent_node . concrete_type_name ( facade . executor () . context () facade . info () )) .