mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-17 20:41:49 +03:00
f01c7f4ee6
In the process of decoupling the schema parsers from the GraphQL Engine, we need to remove dependencies on `Hasura.Base.Error`. First of all, we have avoided using `QErr` in schema parsers code, instead returning a more appropriate data type which can be converted to a `Hasura.Base.Error.QErr` later. Secondly, we create a new `ParseErrorCode` type to represent parse failure types, which are then converted to a `Hasura.Base.Error.Code` later. PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5181 GitOrigin-RevId: 8655e26adb1e7d5e3d552c77a8a403f987b53467
74 lines
1.7 KiB
Haskell
74 lines
1.7 KiB
Haskell
-- | This module exports the public API to our internal GraphQL query parser
|
|
-- combinator language. For more details, see the documentation for 'Parser'.
|
|
module Hasura.GraphQL.Parser
|
|
( Directive (..),
|
|
InputFieldsParser (..),
|
|
FieldParser (..),
|
|
ParsedSelection (..),
|
|
Parser (..),
|
|
parserType,
|
|
runParser,
|
|
bind,
|
|
bindField,
|
|
bindFields,
|
|
boolean,
|
|
int,
|
|
float,
|
|
string,
|
|
identifier,
|
|
uuid,
|
|
json,
|
|
jsonb,
|
|
nonNegativeInt,
|
|
bigInt,
|
|
scientific,
|
|
unsafeRawScalar,
|
|
jsonScalar,
|
|
enum,
|
|
nullable,
|
|
nullableParser,
|
|
nonNullableParser,
|
|
multiple,
|
|
setParserOrigin,
|
|
setFieldParserOrigin,
|
|
setInputFieldsParserOrigin,
|
|
list,
|
|
object,
|
|
selectionSet,
|
|
safeSelectionSet,
|
|
selectionSetInterface,
|
|
selectionSetObject,
|
|
selectionSetUnion,
|
|
field,
|
|
fieldWithDefault,
|
|
fieldOptional,
|
|
wrapFieldParser,
|
|
handleTypename,
|
|
selection,
|
|
rawSelection,
|
|
selection_,
|
|
subselection,
|
|
rawSubselection,
|
|
subselection_,
|
|
jsonToGraphQL,
|
|
valueToJSON,
|
|
module Hasura.GraphQL.Parser.Class,
|
|
module Hasura.GraphQL.Parser.ErrorCode,
|
|
module Hasura.GraphQL.Parser.Monad,
|
|
module Hasura.GraphQL.Parser.Names,
|
|
module Hasura.GraphQL.Parser.Schema,
|
|
module Hasura.GraphQL.Parser.Variable,
|
|
)
|
|
where
|
|
|
|
import Hasura.GraphQL.Parser.Class
|
|
import Hasura.GraphQL.Parser.Directives
|
|
import Hasura.GraphQL.Parser.ErrorCode
|
|
import Hasura.GraphQL.Parser.Internal.Convert
|
|
import Hasura.GraphQL.Parser.Internal.Parser
|
|
import Hasura.GraphQL.Parser.Internal.Scalars
|
|
import Hasura.GraphQL.Parser.Monad
|
|
import Hasura.GraphQL.Parser.Names
|
|
import Hasura.GraphQL.Parser.Schema
|
|
import Hasura.GraphQL.Parser.Variable
|