Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
GQL Types
Synopsis
- class GQLType a where
- type KIND a :: DerivingKind
- directives :: f a -> DirectiveUsages
- class EncodeScalar a where
- encodeScalar :: a -> ScalarValue
- class EncodeWrapper (wrapper :: Type -> Type) where
- encodeWrapper :: Monad m => (a -> m (ResolverValue m)) -> wrapper a -> m (ResolverValue m)
- class DecodeScalar a where
- decodeScalar :: ScalarValue -> Either Text a
- class DecodeWrapper (f :: Type -> Type) where
- decodeWrapper :: (Monad m, DecodeWrapperConstraint f a) => (ValidValue -> m a) -> ValidValue -> ExceptT GQLError m (f a)
- data GQLRequest = GQLRequest {}
- data GQLResponse
- = Data ValidValue
- | Errors [GQLError]
- newtype ID = ID {}
- data ScalarValue
- data Undefined (m :: Type -> Type)
- data Resolver (o :: OperationType) event (m :: Type -> Type) value
- type QUERY = 'OPERATION_QUERY
- type MUTATION = 'OPERATION_MUTATION
- type SUBSCRIPTION = 'OPERATION_SUBSCRIPTION
- lift :: (MonadTrans t, Monad m) => m a -> t m a
- type WithOperation (o :: OperationType) = LiftOperation o
- data ResolverContext = ResolverContext {}
- data SubscriptionField a
- data App event (m :: Type -> Type)
- class RenderGQL a
- render :: RenderGQL a => a -> ByteString
- data TypeGuard interface union
- = ResolveInterface interface
- | ResolveType union
- newtype Arg (name :: Symbol) a = Arg {
- argValue :: a
- data GQLError
- data Prefixes = Prefixes {
- addPrefix :: Text
- removePrefix :: Text
- class VisitType a where
- visitTypeName :: a -> Bool -> Text -> Text
- visitTypeDescription :: a -> Maybe Text -> Maybe Text
- visitFieldNames :: a -> Text -> Text
- visitEnumNames :: a -> Text -> Text
- class VisitField a where
- visitFieldName :: a -> Text -> Text
- visitFieldDescription :: a -> Maybe Text -> Maybe Text
- visitFieldDefaultValue :: a -> Maybe (Value CONST) -> Maybe (Value CONST)
- class VisitEnum a where
- visitEnumName :: a -> Text -> Text
- visitEnumDescription :: a -> Maybe Text -> Maybe Text
- typeDirective :: (GQLDirective a, gql a, args a) => a -> GDirectiveUsages gql args
- fieldDirective :: (GQLDirective a, gql a, args a) => FieldName -> a -> GDirectiveUsages gql args
- enumDirective :: (GQLDirective a, gql a, args a) => TypeName -> a -> GDirectiveUsages gql args
- fieldDirective' :: (GQLDirective a, gql a, args a) => Name -> a -> GDirectiveUsages gql args
- enumDirective' :: (GQLDirective a, gql a, args a) => Name -> a -> GDirectiveUsages gql args
- class (ToLocations (DIRECTIVE_LOCATIONS a), Typeable a, WITH_VISITOR a VISIT_TYPE TYPE_VISITOR_KIND, WITH_VISITOR a VISIT_FIELD FIELD_VISITOR_KIND, WITH_VISITOR a VISIT_ENUM ENUM_VISITOR_KIND) => GQLDirective a where
- type DIRECTIVE_LOCATIONS a :: [DirectiveLocation]
- excludeFromSchema :: f a -> Bool
- newtype Deprecated = Deprecated {}
- newtype Describe = Describe {}
- type SCALAR = 'DERIVING_SCALAR
- data DerivingKind
- type TYPE = 'DERIVING_TYPE
- type CUSTOM = 'DERIVING_CUSTOM
- type WRAPPER = 'DERIVING_WRAPPER
- data RootResolver (m :: Type -> Type) event (query :: (Type -> Type) -> Type) (mutation :: (Type -> Type) -> Type) (subscription :: (Type -> Type) -> Type) = RootResolver {
- queryResolver :: query (Resolver QUERY event m)
- mutationResolver :: mutation (Resolver MUTATION event m)
- subscriptionResolver :: subscription (Resolver SUBSCRIPTION event m)
- defaultRootResolver :: RootResolver m event Undefined Undefined Undefined
- newtype Rename = Rename {}
- newtype InputTypeNamespace = InputTypeNamespace {}
- newtype DropNamespace = DropNamespace {}
- newtype DefaultValue = DefaultValue {}
- data Value (stage :: Stage) where
- ResolvedVariable :: Ref FieldName -> Variable VALID -> Value 'CONST
- VariableValue :: Ref FieldName -> Value 'RAW
- Object :: forall (stage :: Stage). Object stage -> Value stage
- List :: forall (stage :: Stage). [Value stage] -> Value stage
- Enum :: forall (stage :: Stage). TypeName -> Value stage
- Scalar :: forall (stage :: Stage). ScalarValue -> Value stage
- Null :: forall (stage :: Stage). Value stage
- data DirectiveLocation
- = LOCATION_QUERY
- | LOCATION_MUTATION
- | LOCATION_SUBSCRIPTION
- | LOCATION_FIELD
- | LOCATION_FRAGMENT_DEFINITION
- | LOCATION_FRAGMENT_SPREAD
- | LOCATION_INLINE_FRAGMENT
- | LOCATION_SCHEMA
- | LOCATION_SCALAR
- | LOCATION_OBJECT
- | LOCATION_FIELD_DEFINITION
- | LOCATION_ARGUMENT_DEFINITION
- | LOCATION_INTERFACE
- | LOCATION_UNION
- | LOCATION_ENUM
- | LOCATION_ENUM_VALUE
- | LOCATION_INPUT_OBJECT
- | LOCATION_INPUT_FIELD_DEFINITION
- class (Monad m, MonadReader ResolverContext m, MonadFail m, MonadError GQLError m, Monad (MonadParam m)) => MonadResolver (m :: Type -> Type) where
- type MonadOperation (m :: Type -> Type) :: OperationType
- type MonadEvent (m :: Type -> Type)
- type MonadQuery (m :: Type -> Type) :: Type -> Type
- type MonadMutation (m :: Type -> Type) :: Type -> Type
- type MonadSubscription (m :: Type -> Type) :: Type -> Type
- type MonadParam (m :: Type -> Type) :: Type -> Type
- liftState :: ResolverState a -> m a
- getArguments :: m (Arguments VALID)
- subscribe :: MonadOperation m ~ SUBSCRIPTION => Channel (MonadEvent m) -> MonadQuery m (MonadEvent m -> m a) -> SubscriptionField (m a)
- publish :: [MonadEvent m] -> m ()
- runResolver :: Maybe (Selection VALID -> ResolverState (Channel (MonadEvent m))) -> m ValidValue -> ResolverContext -> ResponseStream (MonadEvent m) (MonadParam m) ValidValue
- class (MonadResolver m, MonadIO m) => MonadIOResolver (m :: Type -> Type)
- type family Flexible (m :: Type -> Type) a :: Type
- type family Composed (m :: Type -> Type) f a :: Type
Documentation
class GQLType a where Source #
GraphQL type, every graphQL type should have an instance of Generic
and GQLType
.
... deriving (Generic, GQLType)
if you want to add description
... deriving (Generic) instance GQLType ... where directives _ = typeDirective (Describe "some text")
Nothing
directives :: f a -> DirectiveUsages Source #
Instances
class EncodeScalar a where #
GraphQL Scalar Serializer
encodeScalar :: a -> ScalarValue #
Instances
EncodeScalar ID | |
Defined in Data.Morpheus.Types.ID encodeScalar :: ID -> ScalarValue # | |
EncodeScalar Text | |
Defined in Data.Morpheus.Types.GQLScalar encodeScalar :: Text -> ScalarValue # | |
EncodeScalar Bool | |
Defined in Data.Morpheus.Types.GQLScalar encodeScalar :: Bool -> ScalarValue # | |
EncodeScalar Double | |
Defined in Data.Morpheus.Types.GQLScalar encodeScalar :: Double -> ScalarValue # | |
EncodeScalar Float | |
Defined in Data.Morpheus.Types.GQLScalar encodeScalar :: Float -> ScalarValue # | |
EncodeScalar Int | |
Defined in Data.Morpheus.Types.GQLScalar encodeScalar :: Int -> ScalarValue # |
class EncodeWrapper (wrapper :: Type -> Type) where #
GraphQL Wrapper Serializer
encodeWrapper :: Monad m => (a -> m (ResolverValue m)) -> wrapper a -> m (ResolverValue m) #
Instances
class DecodeScalar a where #
GraphQL Scalar parser
decodeScalar :: ScalarValue -> Either Text a #
Instances
DecodeScalar ID | |
Defined in Data.Morpheus.Types.ID decodeScalar :: ScalarValue -> Either Text ID # | |
DecodeScalar Text | |
Defined in Data.Morpheus.Types.GQLScalar decodeScalar :: ScalarValue -> Either Text Text # | |
DecodeScalar Bool | |
Defined in Data.Morpheus.Types.GQLScalar decodeScalar :: ScalarValue -> Either Text Bool # | |
DecodeScalar Double | |
Defined in Data.Morpheus.Types.GQLScalar decodeScalar :: ScalarValue -> Either Text Double # | |
DecodeScalar Float | |
Defined in Data.Morpheus.Types.GQLScalar decodeScalar :: ScalarValue -> Either Text Float # | |
DecodeScalar Int | |
Defined in Data.Morpheus.Types.GQLScalar decodeScalar :: ScalarValue -> Either Text Int # |
class DecodeWrapper (f :: Type -> Type) where #
GraphQL Wrapper Deserializer
decodeWrapper :: (Monad m, DecodeWrapperConstraint f a) => (ValidValue -> m a) -> ValidValue -> ExceptT GQLError m (f a) #
Instances
data GQLRequest #
GraphQL HTTP Request Body
Instances
data GQLResponse #
GraphQL Response
Instances
default GraphQL type,
parses only ScalarValue
and ScalarValue
values,
serialized always as ScalarValue
Instances
data ScalarValue #
Primitive Values for GQLScalar: ScalarValue
, ScalarValue
, ScalarValue
, Boolean
.
for performance reason type Text
represents GraphQl ScalarValue
value
Instances
data Undefined (m :: Type -> Type) Source #
Instances
data Resolver (o :: OperationType) event (m :: Type -> Type) value #
Instances
type QUERY = 'OPERATION_QUERY #
type MUTATION = 'OPERATION_MUTATION #
type SUBSCRIPTION = 'OPERATION_SUBSCRIPTION #
lift :: (MonadTrans t, Monad m) => m a -> t m a #
Lift a computation from the argument monad to the constructed monad.
type WithOperation (o :: OperationType) = LiftOperation o #
data ResolverContext #
ResolverContext | |
|
Instances
Show ResolverContext | |
Defined in Data.Morpheus.App.Internal.Resolving.ResolverState showsPrec :: Int -> ResolverContext -> ShowS # show :: ResolverContext -> String # showList :: [ResolverContext] -> ShowS # | |
Monad m => MonadReader ResolverContext (ResolverStateT event m) | |
Defined in Data.Morpheus.App.Internal.Resolving.ResolverState ask :: ResolverStateT event m ResolverContext # local :: (ResolverContext -> ResolverContext) -> ResolverStateT event m a -> ResolverStateT event m a # reader :: (ResolverContext -> a) -> ResolverStateT event m a # | |
(LiftOperation o, Monad m) => MonadReader ResolverContext (Resolver o e m) | |
Defined in Data.Morpheus.App.Internal.Resolving.Resolver ask :: Resolver o e m ResolverContext # local :: (ResolverContext -> ResolverContext) -> Resolver o e m a -> Resolver o e m a # reader :: (ResolverContext -> a) -> Resolver o e m a # |
data SubscriptionField a #
Instances
EncodeWrapper SubscriptionField | |
Defined in Data.Morpheus.Types.GQLWrapper encodeWrapper :: Monad m => (a -> m (ResolverValue m)) -> SubscriptionField a -> m (ResolverValue m) # | |
GQLType a => GQLType (SubscriptionField a) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType type KIND (SubscriptionField a) :: DerivingKind Source # directives :: f (SubscriptionField a) -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat (SubscriptionField a) -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c (SubscriptionField a) -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c (SubscriptionField a) -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
type KIND (SubscriptionField a) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType |
Instances
render :: RenderGQL a => a -> ByteString #
data TypeGuard interface union Source #
ResolveInterface interface | |
ResolveType union |
Instances
(DERIVE_TYPE GQLType OUT i, DERIVE_TYPE GQLType OUT u) => GQLType (TypeGuard i u) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType type KIND (TypeGuard i u) :: DerivingKind Source # directives :: f (TypeGuard i u) -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat (TypeGuard i u) -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c (TypeGuard i u) -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c (TypeGuard i u) -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
type KIND (TypeGuard i u) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType |
newtype Arg (name :: Symbol) a Source #
Instances
Generic (Arg name a) Source # | |
Show a => Show (Arg name a) Source # | |
(KnownSymbol name, GQLType value) => GQLType (Arg name value) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType type KIND (Arg name value) :: DerivingKind Source # directives :: f (Arg name value) -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat (Arg name value) -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c (Arg name value) -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c (Arg name value) -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
type Rep (Arg name a) Source # | |
Defined in Data.Morpheus.Server.Types.Types | |
type KIND (Arg name value) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType |
Instances
GQL directives API
a custom GraphQL directive for adding or removing of prefixes
Prefixes | |
|
Instances
class VisitType a where Source #
Nothing
visitTypeName :: a -> Bool -> Text -> Text Source #
Construct a new type name depending on whether it is an input, and being given the original type name.
visitTypeDescription :: a -> Maybe Text -> Maybe Text Source #
visitFieldNames :: a -> Text -> Text Source #
Function applied to field labels. Handy for removing common record prefixes for example.
visitEnumNames :: a -> Text -> Text Source #
Function applied to enum values Handy for removing common enum prefixes for example.
Instances
VisitType Describe Source # | |
VisitType DropNamespace Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions visitTypeName :: DropNamespace -> Bool -> Text -> Text Source # visitTypeDescription :: DropNamespace -> Maybe Text -> Maybe Text Source # visitFieldNames :: DropNamespace -> Text -> Text Source # visitEnumNames :: DropNamespace -> Text -> Text Source # | |
VisitType Prefixes Source # | |
VisitType Rename Source # | |
VisitType InputTypeNamespace Source # | |
Defined in Data.Morpheus.Server.Types.GQLType visitTypeName :: InputTypeNamespace -> Bool -> Text -> Text Source # visitTypeDescription :: InputTypeNamespace -> Maybe Text -> Maybe Text Source # visitFieldNames :: InputTypeNamespace -> Text -> Text Source # visitEnumNames :: InputTypeNamespace -> Text -> Text Source # |
class VisitField a where Source #
Nothing
visitFieldName :: a -> Text -> Text Source #
visitFieldDescription :: a -> Maybe Text -> Maybe Text Source #
visitFieldDefaultValue :: a -> Maybe (Value CONST) -> Maybe (Value CONST) Source #
Instances
VisitField DefaultValue Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions visitFieldName :: DefaultValue -> Text -> Text Source # visitFieldDescription :: DefaultValue -> Maybe Text -> Maybe Text Source # visitFieldDefaultValue :: DefaultValue -> Maybe (Value CONST) -> Maybe (Value CONST) Source # | |
VisitField Deprecated Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions visitFieldName :: Deprecated -> Text -> Text Source # visitFieldDescription :: Deprecated -> Maybe Text -> Maybe Text Source # visitFieldDefaultValue :: Deprecated -> Maybe (Value CONST) -> Maybe (Value CONST) Source # | |
VisitField Describe Source # | |
VisitField Rename Source # | |
class VisitEnum a where Source #
Nothing
visitEnumName :: a -> Text -> Text Source #
visitEnumDescription :: a -> Maybe Text -> Maybe Text Source #
Instances
VisitEnum Deprecated Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions visitEnumName :: Deprecated -> Text -> Text Source # visitEnumDescription :: Deprecated -> Maybe Text -> Maybe Text Source # | |
VisitEnum Describe Source # | |
VisitEnum Rename Source # | |
typeDirective :: (GQLDirective a, gql a, args a) => a -> GDirectiveUsages gql args Source #
fieldDirective :: (GQLDirective a, gql a, args a) => FieldName -> a -> GDirectiveUsages gql args Source #
enumDirective :: (GQLDirective a, gql a, args a) => TypeName -> a -> GDirectiveUsages gql args Source #
fieldDirective' :: (GQLDirective a, gql a, args a) => Name -> a -> GDirectiveUsages gql args Source #
enumDirective' :: (GQLDirective a, gql a, args a) => Name -> a -> GDirectiveUsages gql args Source #
default GQL directives
class (ToLocations (DIRECTIVE_LOCATIONS a), Typeable a, WITH_VISITOR a VISIT_TYPE TYPE_VISITOR_KIND, WITH_VISITOR a VISIT_FIELD FIELD_VISITOR_KIND, WITH_VISITOR a VISIT_ENUM ENUM_VISITOR_KIND) => GQLDirective a where Source #
Nothing
type DIRECTIVE_LOCATIONS a :: [DirectiveLocation] Source #
excludeFromSchema :: f a -> Bool Source #
Instances
newtype Deprecated Source #
Instances
Instances
Generic Describe Source # | |
GQLDirective Describe Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions type DIRECTIVE_LOCATIONS Describe :: [DirectiveLocation] Source # excludeFromSchema :: f Describe -> Bool Source # | |
GQLType Describe Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions type KIND Describe :: DerivingKind Source # directives :: f Describe -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat Describe -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c Describe -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c Describe -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
VisitEnum Describe Source # | |
VisitField Describe Source # | |
VisitType Describe Source # | |
type Rep Describe Source # | |
type DIRECTIVE_LOCATIONS Describe Source # | |
type KIND Describe Source # | |
type SCALAR = 'DERIVING_SCALAR Source #
GraphQL Scalar: Int, Float, String, Boolean or any user defined custom Scalar type
data DerivingKind Source #
Instances
Show DerivingKind Source # | |
Defined in Data.Morpheus.Server.Types.Kind showsPrec :: Int -> DerivingKind -> ShowS # show :: DerivingKind -> String # showList :: [DerivingKind] -> ShowS # |
data RootResolver (m :: Type -> Type) event (query :: (Type -> Type) -> Type) (mutation :: (Type -> Type) -> Type) (subscription :: (Type -> Type) -> Type) Source #
GraphQL Root resolver, also the interpreter generates a GQL schema from it.
queryResolver
is required, mutationResolver
and subscriptionResolver
are optional,
if your schema does not supports mutation or subscription , you can use () for it.
RootResolver | |
|
defaultRootResolver :: RootResolver m event Undefined Undefined Undefined Source #
a custom GraphQL directive for adding or removing of prefixes
Instances
Generic Rename Source # | |
GQLDirective Rename Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions type DIRECTIVE_LOCATIONS Rename :: [DirectiveLocation] Source # excludeFromSchema :: f Rename -> Bool Source # | |
GQLType Rename Source # | |
Defined in Data.Morpheus.Server.Types.DirectiveDefinitions type KIND Rename :: DerivingKind Source # directives :: f Rename -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat Rename -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c Rename -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c Rename -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
VisitEnum Rename Source # | |
VisitField Rename Source # | |
VisitType Rename Source # | |
type Rep Rename Source # | |
type DIRECTIVE_LOCATIONS Rename Source # | |
type KIND Rename Source # | |
newtype InputTypeNamespace Source #
Instances
newtype DropNamespace Source #
Instances
newtype DefaultValue Source #
Instances
data Value (stage :: Stage) where #
ResolvedVariable :: Ref FieldName -> Variable VALID -> Value 'CONST | |
VariableValue :: Ref FieldName -> Value 'RAW | |
Object :: forall (stage :: Stage). Object stage -> Value stage | |
List :: forall (stage :: Stage). [Value stage] -> Value stage | |
Enum :: forall (stage :: Stage). TypeName -> Value stage | |
Scalar :: forall (stage :: Stage). ScalarValue -> Value stage | |
Null :: forall (stage :: Stage). Value stage |
Instances
Lift (Value a :: Type) | |
FromJSON (Value a) | |
ToJSON (Value a) | |
Defined in Data.Morpheus.Types.Internal.AST.Value | |
IsString (Value stage) | |
Defined in Data.Morpheus.Types.Internal.AST.Value fromString :: String -> Value stage # | |
Show (Value a) | |
Eq (Value s) | |
Hashable (Value a) | |
Defined in Data.Morpheus.Types.Internal.AST.Value | |
RenderGQL (Value a) | |
Defined in Data.Morpheus.Types.Internal.AST.Value | |
Msg (Value a) | |
Defined in Data.Morpheus.Types.Internal.AST.Value | |
GQLType (Value CONST) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType directives :: f (Value CONST) -> DirectiveUsages Source # __type :: forall (cat :: TypeCategory). CatType cat (Value CONST) -> TypeData __deriveType :: forall (c :: TypeCategory). CatType c (Value CONST) -> SchemaT c (TypeDefinition c CONST) __deriveFieldArguments :: forall (c :: TypeCategory). CatType c (Value CONST) -> SchemaT c (Maybe (ArgumentsDefinition CONST)) | |
type KIND (Value CONST) Source # | |
Defined in Data.Morpheus.Server.Types.GQLType |
data DirectiveLocation #
Instances
Show DirectiveLocation | |
Defined in Data.Morpheus.Types.Internal.AST.DirectiveLocation showsPrec :: Int -> DirectiveLocation -> ShowS # show :: DirectiveLocation -> String # showList :: [DirectiveLocation] -> ShowS # | |
Eq DirectiveLocation | |
Defined in Data.Morpheus.Types.Internal.AST.DirectiveLocation (==) :: DirectiveLocation -> DirectiveLocation -> Bool # (/=) :: DirectiveLocation -> DirectiveLocation -> Bool # | |
RenderGQL DirectiveLocation | |
Defined in Data.Morpheus.Types.Internal.AST.DirectiveLocation renderGQL :: DirectiveLocation -> Rendering # | |
Msg DirectiveLocation | |
Defined in Data.Morpheus.Types.Internal.AST.DirectiveLocation msg :: DirectiveLocation -> GQLError # | |
Lift DirectiveLocation | |
Defined in Data.Morpheus.Types.Internal.AST.DirectiveLocation lift :: Quote m => DirectiveLocation -> m Exp # liftTyped :: forall (m :: Type -> Type). Quote m => DirectiveLocation -> Code m DirectiveLocation # |
class (Monad m, MonadReader ResolverContext m, MonadFail m, MonadError GQLError m, Monad (MonadParam m)) => MonadResolver (m :: Type -> Type) where #
type MonadOperation (m :: Type -> Type) :: OperationType #
type MonadEvent (m :: Type -> Type) #
type MonadQuery (m :: Type -> Type) :: Type -> Type #
type MonadMutation (m :: Type -> Type) :: Type -> Type #
type MonadSubscription (m :: Type -> Type) :: Type -> Type #
liftState :: ResolverState a -> m a #
getArguments :: m (Arguments VALID) #
subscribe :: MonadOperation m ~ SUBSCRIPTION => Channel (MonadEvent m) -> MonadQuery m (MonadEvent m -> m a) -> SubscriptionField (m a) #
publish :: [MonadEvent m] -> m () #
runResolver :: Maybe (Selection VALID -> ResolverState (Channel (MonadEvent m))) -> m ValidValue -> ResolverContext -> ResponseStream (MonadEvent m) (MonadParam m) ValidValue #
Instances
class (MonadResolver m, MonadIO m) => MonadIOResolver (m :: Type -> Type) #
Instances
(LiftOperation o, Monad m, MonadIO m) => MonadIOResolver (Resolver o e m) | |