import * as graphqlTypes from "graphql"; import { StorageRegistry } from '@worldbrain/storex'; import { StorageModuleInterface } from '@worldbrain/storex-pattern-modules'; import { PublicMethodDefinition, PublicMethodValues, PublicMethodValue, PublicMethodValueType, PublicMethodObjectType, PublicMethodDetailedValue } from "@worldbrain/storex-pattern-modules/lib/types"; import { AutoPkType, StorexGraphQLSchemaEvent } from "./types"; declare type CommonOptions = { autoPkType: AutoPkType; graphql: typeof graphqlTypes; observer?: (event: StorexGraphQLSchemaEvent) => void; }; declare type CommonOptionsWithTypes = CommonOptions & { collectionTypes: any; collectionInputs: any; voidType: any; }; export declare function createStorexGraphQLSchema(modules: { [name: string]: StorageModuleInterface; }, options: { storageRegistry: StorageRegistry; } & CommonOptions): graphqlTypes.GraphQLSchema; export declare function moduleToGraphQL(module: StorageModuleInterface, moduleName: string, options: { type: 'query' | 'mutation'; } & CommonOptionsWithTypes): { type: graphqlTypes.GraphQLObjectType; resolve: () => {}; }; export declare function methodToGraphQL(method: Function, methodName: string, definition: PublicMethodDefinition, options: { moduleName: string; } & CommonOptionsWithTypes): { type: any; args: {}; resolve: (parent: any, argsObject: any) => Promise; }; export declare function valuesToGraphQL(values: PublicMethodValues, options: CommonOptionsWithTypes & { asInput?: boolean; }): {}; export declare function returnTypeToGraphQL(methodDefinition: PublicMethodDefinition, methodName: string, options: { moduleName: string; } & CommonOptionsWithTypes): any; export declare function objectValueTypeToGraphQL(value: PublicMethodDetailedValue, name: string, options: CommonOptionsWithTypes): graphqlTypes.GraphQLObjectType | graphqlTypes.GraphQLNonNull; export declare function valueToGraphQL(value: PublicMethodValue, options: CommonOptionsWithTypes & { asInput?: boolean; }): any; export declare function valueTypeToGraphQL(valueType: PublicMethodValueType, options: CommonOptionsWithTypes & { asInput?: boolean; }): any; export declare function storexGraphQLSchemaLogger(options: { eventTypes: string[] | 'all'; }): (event: StorexGraphQLSchemaEvent) => void; export {};