Module: GraphQL::DefinitionHelpers::NonNullWithBang

Included in:
EnumType, ObjectType, UnionType
Defined in:
lib/graph_ql/definition_helpers/non_null_with_bang.rb

Overview

Wrap the object in NonNullType in response to ‘!`

Examples:

required Int type

!GraphQL::INT_TYPE

Instance Method Summary collapse

Instance Method Details

#!GraphQL::NonNullType

Make the type non-null

Returns:

  • a non-null type which wraps the original type



8
9
10
# File 'lib/graph_ql/definition_helpers/non_null_with_bang.rb', line 8

def !
  GraphQL::NonNullType.new(of_type: self)
end