GraphQL::Type - GraphQL type object
Superclass for other GraphQL type classes to inherit from.
Those Perl classes each implement a GraphQL type. Each item of GraphQL data has a GraphQL type. Such an item of data can also be represented within Perl. Objects of that Perl class take responsibility for translating between the Perl representation and the "GraphQL representation". A "GraphQL representation" means something JSON-encodeable: an "object" (in Perl terms, a hash), an array (Perl: array-reference), string, number, boolean, or null.
See "METHODS" for generic methods to translate back and forth between these worlds.
Code that you provide to do this translation must return things that can be JSON-encoded, not things that have been so encoded: this means, among other things, do not surround strings in
", and for boolean values, use the mechanism in JSON::MaybeXS:
These subclasses implement part of the GraphQL language specification. Objects of these classes implement user-defined types used to implement a GraphQL API.
These roles implement part of the GraphQL language specification. They are applied to objects of GraphQL::Type classes, either to facilitate type constrants, or as noted below.
fieldsattribute for an input type
fieldsattribute for an output type
description, provided by this role
Shallow copy of the object, suitable for reblessing without affecting the original object.
Turn given Perl entity into valid Perl value for this type if possible.
Turn given GraphQL entity into Perl entity.
Turn given Perl entity into GraphQL entity.