Class: ArSerializer::GraphQL::OptionalTypeClass
- Inherits:
-
TypeClass
- Object
- TypeClass
- ArSerializer::GraphQL::OptionalTypeClass
show all
- Defined in:
- lib/ar_serializer/graphql/types.rb
Instance Attribute Summary
Attributes inherited from TypeClass
#except, #only, #type
Instance Method Summary
collapse
Methods inherited from TypeClass
#description, #fields, from, #initialize, #validate!
Instance Method Details
#association_type ⇒ Object
357
358
359
|
# File 'lib/ar_serializer/graphql/types.rb', line 357
def association_type
of_type.association_type
end
|
#collect_types(types) ⇒ Object
361
362
363
|
# File 'lib/ar_serializer/graphql/types.rb', line 361
def collect_types(types)
of_type.collect_types types
end
|
#gql_type ⇒ Object
365
366
367
|
# File 'lib/ar_serializer/graphql/types.rb', line 365
def gql_type
of_type.gql_type
end
|
#kind ⇒ Object
345
346
347
|
# File 'lib/ar_serializer/graphql/types.rb', line 345
def kind
of_type.kind
end
|
#name ⇒ Object
349
350
351
|
# File 'lib/ar_serializer/graphql/types.rb', line 349
def name
of_type.name
end
|
#of_type ⇒ Object
353
354
355
|
# File 'lib/ar_serializer/graphql/types.rb', line 353
def of_type
TypeClass.from type.first, only, except
end
|
#sample ⇒ Object
369
370
371
|
# File 'lib/ar_serializer/graphql/types.rb', line 369
def sample
nil
end
|
#ts_type ⇒ Object
373
374
375
|
# File 'lib/ar_serializer/graphql/types.rb', line 373
def ts_type
"(#{of_type.ts_type} | null)"
end
|