Class: GraphQL::ObjectType::Printer

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/graph_ql/types/object_type.rb

Instance Method Summary collapse

Instance Method Details



56
57
58
59
60
61
62
63
64
# File 'lib/graph_ql/types/object_type.rb', line 56

def print(type)
  if type.kind.non_null?
    "#{print(type.of_type)}!"
  elsif type.kind.list?
    "[#{print(type.of_type)}]"
  else
    type.name
  end
end