Safe Haskell | None |
---|---|
Language | Haskell2010 |
Hasura.RQL.Types.CustomTypes
Synopsis
- newtype GraphQLType = GraphQLType {
- unGraphQLType :: GType
- isListType :: GraphQLType -> Bool
- isNullableType :: GraphQLType -> Bool
- isInBuiltScalar :: Text -> Bool
- data CustomTypes = CustomTypes {}
- emptyCustomTypes :: CustomTypes
- data InputObjectTypeDefinition = InputObjectTypeDefinition {
- _iotdName :: InputObjectTypeName
- _iotdDescription :: Maybe Description
- _iotdFields :: NonEmpty InputObjectFieldDefinition
- newtype InputObjectTypeName = InputObjectTypeName {
- unInputObjectTypeName :: Name
- data InputObjectFieldDefinition = InputObjectFieldDefinition {
- _iofdName :: InputObjectFieldName
- _iofdDescription :: Maybe Description
- _iofdType :: GraphQLType
- newtype InputObjectFieldName = InputObjectFieldName {
- unInputObjectFieldName :: Name
- data ObjectTypeDefinition = ObjectTypeDefinition {
- _otdName :: ObjectTypeName
- _otdDescription :: Maybe Description
- _otdFields :: NonEmpty (ObjectFieldDefinition GraphQLType)
- _otdRelationships :: [TypeRelationshipDefinition]
- newtype ObjectTypeName = ObjectTypeName {
- unObjectTypeName :: Name
- data ObjectFieldDefinition field = ObjectFieldDefinition {
- _ofdName :: ObjectFieldName
- _ofdArguments :: Maybe Value
- _ofdDescription :: Maybe Description
- _ofdType :: field
- newtype ObjectFieldName = ObjectFieldName {
- unObjectFieldName :: Name
- data ScalarTypeDefinition = ScalarTypeDefinition {
- _stdName :: Name
- _stdDescription :: Maybe Description
- defaultGraphQLScalars :: HashMap Name ScalarTypeDefinition
- data EnumTypeDefinition = EnumTypeDefinition {
- _etdName :: EnumTypeName
- _etdDescription :: Maybe Description
- _etdValues :: NonEmpty EnumValueDefinition
- newtype EnumTypeName = EnumTypeName {
- unEnumTypeName :: Name
- data EnumValueDefinition = EnumValueDefinition {
- _evdValue :: EnumValue
- _evdDescription :: Maybe Description
- _evdIsDeprecated :: Maybe Bool
- data TypeRelationshipDefinition = TypeRelationshipDefinition {}
- newtype RelationshipName = RelationshipName {
- unRelationshipName :: Name
- data AnnotatedCustomTypes = AnnotatedCustomTypes {
- _actInputTypes :: HashMap Name AnnotatedInputType
- _actObjectTypes :: HashMap Name AnnotatedObjectType
- data AnnotatedInputType
- data AnnotatedScalarType
- newtype ScalarWrapper b = ScalarWrapper {
- unwrapScalar :: ScalarType b
- data AnnotatedOutputType
- data AnnotatedObjectType = AnnotatedObjectType {
- _aotName :: ObjectTypeName
- _aotDescription :: Maybe Description
- _aotFields :: NonEmpty (ObjectFieldDefinition (GType, AnnotatedObjectFieldType))
- _aotRelationships :: [AnnotatedTypeRelationship]
- data AnnotatedObjectFieldType
- data AnnotatedTypeRelationship = AnnotatedTypeRelationship {}
- trdType :: Lens' TypeRelationshipDefinition RelType
- trdSource :: Lens' TypeRelationshipDefinition SourceName
- trdRemoteTable :: Lens' TypeRelationshipDefinition QualifiedTable
- trdName :: Lens' TypeRelationshipDefinition RelationshipName
- trdFieldMapping :: Lens' TypeRelationshipDefinition (HashMap ObjectFieldName PGCol)
Documentation
newtype GraphQLType Source #
A wrapper around GType
which allows us to define custom JSON
instances.
TODO: this name is ambiguous, and conflicts with Hasura.RQL.DDL.RemoteSchema.Permission.GraphQLType; it should perhaps be renamed, made internal to this module, or removed altogether?
Constructors
GraphQLType | |
Fields
|
Instances
isListType :: GraphQLType -> Bool Source #
isNullableType :: GraphQLType -> Bool Source #
isInBuiltScalar :: Text -> Bool Source #
data CustomTypes Source #
A set of custom GraphQL types, sorted by "kind".
Constructors
CustomTypes | |
Fields |
Instances
data InputObjectTypeDefinition Source #
Constructors
InputObjectTypeDefinition | |
Fields
|
Instances
newtype InputObjectTypeName Source #
Constructors
InputObjectTypeName | |
Fields
|
Instances
data InputObjectFieldDefinition Source #
Constructors
InputObjectFieldDefinition | |
Fields
|
Instances
newtype InputObjectFieldName Source #
Constructors
InputObjectFieldName | |
Fields
|
Instances
data ObjectTypeDefinition Source #
Constructors
ObjectTypeDefinition | |
Fields
|
Instances
newtype ObjectTypeName Source #
Constructors
ObjectTypeName | |
Fields
|
Instances
data ObjectFieldDefinition field Source #
Constructors
ObjectFieldDefinition | |
Fields
|
Instances
newtype ObjectFieldName Source #
Constructors
ObjectFieldName | |
Fields
|
Instances
data ScalarTypeDefinition Source #
Constructors
ScalarTypeDefinition | |
Fields
|
Instances
defaultGraphQLScalars :: HashMap Name ScalarTypeDefinition Source #
data EnumTypeDefinition Source #
Constructors
EnumTypeDefinition | |
Fields
|
Instances
newtype EnumTypeName Source #
Constructors
EnumTypeName | |
Fields
|
Instances
data EnumValueDefinition Source #
Constructors
EnumValueDefinition | |
Fields
|
Instances
data TypeRelationshipDefinition Source #
Constructors
TypeRelationshipDefinition | |
Fields
|
Instances
newtype RelationshipName Source #
TODO: deduplicate this in favour of RelName
Constructors
RelationshipName | |
Fields
|
Instances
data AnnotatedCustomTypes Source #
While we do not persist resolved types in the schema cache, they are used when building the cache to validate and resolve actions and their relationships.
Constructors
AnnotatedCustomTypes | |
Fields
|
Instances
Semigroup AnnotatedCustomTypes Source # | |
Defined in Hasura.RQL.Types.CustomTypes Methods (<>) :: AnnotatedCustomTypes -> AnnotatedCustomTypes -> AnnotatedCustomTypes # sconcat :: NonEmpty AnnotatedCustomTypes -> AnnotatedCustomTypes # stimes :: Integral b => b -> AnnotatedCustomTypes -> AnnotatedCustomTypes # | |
Monoid AnnotatedCustomTypes Source # | |
Defined in Hasura.RQL.Types.CustomTypes Methods mempty :: AnnotatedCustomTypes # mappend :: AnnotatedCustomTypes -> AnnotatedCustomTypes -> AnnotatedCustomTypes # |
data AnnotatedInputType Source #
Constructors
NOCTScalar AnnotatedScalarType | |
NOCTEnum EnumTypeDefinition | |
NOCTInputObject InputObjectTypeDefinition |
Instances
data AnnotatedScalarType Source #
Constructors
ASTCustom ScalarTypeDefinition | |
ASTReusedScalar Name (AnyBackend ScalarWrapper) |
Instances
newtype ScalarWrapper b Source #
Constructors
ScalarWrapper | |
Fields
|
Instances
Backend b => Eq (ScalarWrapper b) Source # | |
Defined in Hasura.RQL.Types.CustomTypes Methods (==) :: ScalarWrapper b -> ScalarWrapper b -> Bool # (/=) :: ScalarWrapper b -> ScalarWrapper b -> Bool # |
data AnnotatedOutputType Source #
Constructors
AOTObject AnnotatedObjectType | |
AOTScalar AnnotatedScalarType |
Instances
data AnnotatedObjectType Source #
Constructors
AnnotatedObjectType | |
Fields
|
Instances
data AnnotatedObjectFieldType Source #
Constructors
AOFTScalar AnnotatedScalarType | |
AOFTEnum EnumTypeDefinition | |
AOFTObject Name |
Instances
data AnnotatedTypeRelationship Source #
Constructors
AnnotatedTypeRelationship | |
Fields
|
Instances
trdType :: Lens' TypeRelationshipDefinition RelType Source #
trdSource :: Lens' TypeRelationshipDefinition SourceName Source #
trdFieldMapping :: Lens' TypeRelationshipDefinition (HashMap ObjectFieldName PGCol) Source #