import { Rule, AST, Linter } from 'eslint';
import { ASTNode, GraphQLSchema } from 'graphql';
import { GraphQLParseOptions } from '@graphql-tools/utils';
import { IExtensions, IGraphQLProject, DocumentPointer, SchemaPointer } from 'graphql-config';
import { GraphQLESLintRuleListener } from './testkit';
import { GraphQLESTreeNode } from './estree-parser';
import { SiblingOperations } from './sibling-operations';
import { getReachableTypes, getUsedFields } from './graphql-ast';
export interface ParserOptions {
    schema?: SchemaPointer | Record<string, {
        headers: Record<string, string>;
    }>;
    documents?: DocumentPointer;
    operations?: DocumentPointer;
    extensions?: IExtensions;
    include?: string | string[];
    exclude?: string | string[];
    projects?: Record<string, IGraphQLProject>;
    schemaOptions?: Omit<GraphQLParseOptions, 'assumeValidSDL'> & {
        headers: Record<string, string>;
    };
    graphQLParserOptions?: Omit<GraphQLParseOptions, 'noLocation'>;
    skipGraphQLConfig?: boolean;
    filePath?: string;
}
export declare type ParserServices = {
    hasTypeInfo: boolean;
    schema: GraphQLSchema | null;
    siblingOperations: SiblingOperations;
    reachableTypes: typeof getReachableTypes;
    usedFields: typeof getUsedFields;
};
export declare type GraphQLESLintParseResult = Linter.ESLintParseResult & {
    services: ParserServices;
};
export declare type GraphQLESLintRuleContext<Options = any[]> = Omit<Rule.RuleContext, 'parserServices' | 'report' | 'options'> & {
    options: Options;
    report(descriptor: Rule.ReportDescriptorMessage & Rule.ReportDescriptorOptions & ({
        node: GraphQLESTreeNode<ASTNode>;
    } | {
        loc: AST.SourceLocation | {
            line: number;
            column: number;
        };
    })): void;
    parserServices?: ParserServices;
};
export declare type CategoryType = 'Schema' | 'Operations';
export declare type RuleDocsInfo<T> = {
    docs: Omit<Rule.RuleMetaData['docs'], 'category'> & {
        category: CategoryType | CategoryType[];
        requiresSchema?: boolean;
        requiresSiblings?: boolean;
        examples?: {
            title: string;
            code: string;
            usage?: T;
        }[];
        configOptions?: T | {
            schema?: T;
            operations?: T;
        };
        graphQLJSRuleName?: string;
    };
};
export declare type GraphQLESLintRule<Options = any[], WithTypeInfo extends boolean = false> = {
    create(context: GraphQLESLintRuleContext<Options>): GraphQLESLintRuleListener<WithTypeInfo>;
    meta: Omit<Rule.RuleMetaData, 'docs'> & RuleDocsInfo<Options>;
};
export declare type ValueOf<T> = T[keyof T];
