import { type DataRecord, type ForeignKeyRestriction } from '@overture-stack/lectern-dictionary'; import { type TestResult } from '../types'; import type { SchemaDataReference } from './collectSchemaReferenceData'; import type { DictionaryValidationErrorRecordForeignKey } from './DictionaryValidationError'; /** * Test foreignKey restrictions on a single DataRecord, checked against a pre-calculated `foreignSchemaRefereceData` with the values * of relevant fields from foreign schemas. The `foreignSchemaRefereceData` can be created using `collectSchemaReferenceData`. * * Since foreignKey restrictions contain nested arrays, this test is a double loop over: * 1. Foreign Schema name * 2. Field name in foreign schema * * This is because each foreign key rule is an array of arrays, representing multiple foreign schemas with multiple foreign fields that * must be matched to a local field. */ export declare const testForeignKeyRestriction: (record: DataRecord, foreignKeyRestrictions: ForeignKeyRestriction[], foreignSchemaReferenceData: Map) => TestResult;