Class: GraphQL::Introspection::SchemaType
- Inherits:
-
Introspection::BaseObject
- Object
- Introspection::BaseObject
- GraphQL::Introspection::SchemaType
- Defined in:
- lib/graphql/introspection/schema_type.rb
Class Method Summary collapse
Instance Method Summary collapse
- #directives ⇒ Object
- #mutation_type ⇒ Object
- #query_type ⇒ Object
- #schema_description ⇒ Object
- #subscription_type ⇒ Object
- #types ⇒ Object
Class Method Details
.schema_description(context) ⇒ Object
18 19 20 |
# File 'lib/graphql/introspection/schema_type.rb', line 18 def self.schema_description(context) context.schema.description end |
Instance Method Details
#directives ⇒ Object
45 46 47 |
# File 'lib/graphql/introspection/schema_type.rb', line 45 def directives @context.types.directives.sort_by(&:graphql_name) end |
#mutation_type ⇒ Object
37 38 39 |
# File 'lib/graphql/introspection/schema_type.rb', line 37 def mutation_type @context.types.mutation_root end |
#query_type ⇒ Object
33 34 35 |
# File 'lib/graphql/introspection/schema_type.rb', line 33 def query_type @context.types.query_root end |
#schema_description ⇒ Object
22 23 24 |
# File 'lib/graphql/introspection/schema_type.rb', line 22 def schema_description self.class.schema_description(context) end |
#subscription_type ⇒ Object
41 42 43 |
# File 'lib/graphql/introspection/schema_type.rb', line 41 def subscription_type @context.types.subscription_root end |
#types ⇒ Object
26 27 28 29 30 31 |
# File 'lib/graphql/introspection/schema_type.rb', line 26 def types query_types = context.types.all_types types = query_types + context.schema.extra_types types.sort_by!(&:graphql_name) types end |