Class: GraphQL::InputObjectType
Instance Method Summary
collapse
Methods inherited from ObjectType
#fields, #fields=, #initialize, #inspect, #interfaces
Methods included from Definable
#attr_definable
#!
Instance Method Details
4
5
6
7
8
9
10
11
12
|
# File 'lib/graph_ql/types/input_object_type.rb', line 4
def input_fields(new_fields=nil)
if new_fields.nil?
@new_fields
else
@new_fields = new_fields
.reduce({}) {|memo, (k, v)| memo[k.to_s] = v; memo}
.each { |k, v| v.respond_to?("name=") && v.name = k}
end
end
|
#kind ⇒ Object
14
15
16
|
# File 'lib/graph_ql/types/input_object_type.rb', line 14
def kind
GraphQL::TypeKinds::INPUT_OBJECT
end
|
#to_s ⇒ Object
18
19
20
|
# File 'lib/graph_ql/types/input_object_type.rb', line 18
def to_s
"<GraphQL::InputObjectType #{name}>"
end
|