{-# LANGUAGE DataKinds #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE TypeFamilies #-}
module Data.Morpheus.Kind
( SCALAR,
OBJECT,
ENUM,
WRAPPER,
UNION,
INPUT_OBJECT,
GQL_KIND,
Context (..),
VContext (..),
ResContext (..),
OUTPUT,
INPUT,
INTERFACE,
)
where
import Data.Morpheus.Types.Internal.AST
( OperationType (..),
)
data GQL_KIND
= SCALAR
| ENUM
| INPUT
| OUTPUT
| WRAPPER
| INTERFACE
data ResContext (kind :: GQL_KIND) (operation :: OperationType) event (m :: * -> *) value = ResContext
data Context (kind :: GQL_KIND) a
= Context
newtype VContext (kind :: GQL_KIND) a = VContext
{ unVContext :: a
}
type SCALAR = 'SCALAR
type ENUM = 'ENUM
type WRAPPER = 'WRAPPER
type OUTPUT = 'OUTPUT
type INPUT = 'INPUT
{-# DEPRECATED INPUT_OBJECT "use more generalised kind: INPUT" #-}
type INPUT_OBJECT = 'INPUT
{-# DEPRECATED UNION "use: deriving(GQLType), INPORTANT: only types with <type constructor name><constructor name> will sustain their form, other union constructors will be wrapped inside an new object" #-}
type UNION = 'OUTPUT
{-# DEPRECATED OBJECT "use: deriving(GQLType), will be automatically inferred" #-}
type OBJECT = 'OUTPUT
type INTERFACE = 'INTERFACE