import { FieldMapEntry, ResolverReferenceEntry, TransformerContextProvider, TransformerResourceHelperProvider } from '@aws-amplify/graphql-transformer-interfaces';
import type { TransformParameters } from '@aws-amplify/graphql-transformer-interfaces';
import { DirectiveNode, FieldDefinitionNode, ObjectTypeDefinitionNode } from 'graphql';
import { BelongsToDirectiveConfiguration, HasManyDirectiveConfiguration, HasOneDirectiveConfiguration, ManyToManyDirectiveConfiguration } from './types';
export declare const validateParentReferencesFields: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration, ctx: TransformerContextProvider) => void;
export declare const validateChildReferencesFields: (config: BelongsToDirectiveConfiguration, ctx: TransformerContextProvider) => void;
export declare const getRelatedTypeIndex: (config: HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration, ctx: TransformerContextProvider, indexName?: string) => FieldDefinitionNode[];
export declare const ensureFieldsArray: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration) => void;
export declare const ensureReferencesArray: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration) => void;
export declare const ensureReferencesBidirectionality: (config: HasManyDirectiveConfiguration | BelongsToDirectiveConfiguration) => void;
export declare const getModelDirective: (objectType: ObjectTypeDefinitionNode) => DirectiveNode | undefined;
export declare const validateModelDirective: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration | ManyToManyDirectiveConfiguration) => void;
export declare const getRelatedType: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration, ctx: TransformerContextProvider) => ObjectTypeDefinitionNode;
export declare const getFieldsNodes: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration, ctx: TransformerContextProvider) => FieldDefinitionNode[];
export declare const getReferencesNodes: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration, ctx: TransformerContextProvider) => FieldDefinitionNode[];
export declare const getBelongsToReferencesNodes: (config: BelongsToDirectiveConfiguration, ctx: TransformerContextProvider) => FieldDefinitionNode[];
export declare const validateRelatedModelDirective: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration | BelongsToDirectiveConfiguration) => void;
export declare const getConnectionAttributeName: (transformParameters: TransformParameters, type: string, field: string, relatedTypeField: string) => string;
export declare const getManyToManyConnectionAttributeName: (transformParameters: TransformParameters, field: string, relatedTypeField: string) => string;
export declare const getSortKeyConnectionAttributeName: (type: string, field: string, relatedTypeField: string) => string;
export declare const getBackendConnectionAttributeName: (transformParameters: TransformParameters, resourceHelper: TransformerResourceHelperProvider, type: string, field: string, relatedTypeField: string) => string;
export declare const validateDisallowedDataStoreRelationships: (config: HasManyDirectiveConfiguration | HasOneDirectiveConfiguration, ctx: TransformerContextProvider) => void;
type RegisterForeignKeyMappingParams = {
    transformParameters: TransformParameters;
    resourceHelper: TransformerResourceHelperProvider;
    thisTypeName: string;
    thisFieldName: string;
    relatedType: ObjectTypeDefinitionNode;
};
export declare const registerHasOneForeignKeyMappings: ({ transformParameters, resourceHelper, thisTypeName, thisFieldName, relatedType, }: RegisterForeignKeyMappingParams) => void;
export declare const registerHasManyForeignKeyMappings: ({ transformParameters, resourceHelper, thisTypeName, thisFieldName, relatedType, }: RegisterForeignKeyMappingParams) => void;
export type ManyToManyForeignKeyMappingParams = {
    resourceHelper: TransformerResourceHelperProvider;
    typeName: string;
    referencedBy: ResolverReferenceEntry[];
    fieldMap: FieldMapEntry[];
};
export declare const registerManyToManyForeignKeyMappings: ({ resourceHelper, typeName, referencedBy, fieldMap, }: ManyToManyForeignKeyMappingParams) => void;
export declare const getObjectPrimaryKey: (object: ObjectTypeDefinitionNode) => FieldDefinitionNode;
export {};
//# sourceMappingURL=utils.d.ts.map