import { BaseCollection } from "./BaseCollection.js"; import { BuildResult, CollectionArray, FieldRuleReference, Rule, RuleCondition, RuleStringConditions, ValidationFunction } from "../types.js"; import { RecordHolder } from "./RecordHolder.js"; export declare class Collection>, COLLECTIONS extends CollectionArray> extends RecordHolder implements BaseCollection { #private; readonly name: NAME; readonly fields: FIELDS; readonly collections: COLLECTIONS; _allowCollectionGroupListIf: Rule | null; readonly documentIdVar: string; constructor(name: NAME, documentIdVar: string, fields: FIELDS, collections: COLLECTIONS); get relativePath(): string; allowAccessRemovingEdits(): void; allowFullAccessIf(rule: Rule): this; allowGetIf(rule: Rule): this; allowCreateIf(rule: Rule): this; allowUpdateIf(rule: Rule): this; allowDeleteIf(rule: Rule): this; allowListIf(rule: Rule): this; /** * Specifies a rule that allows users to search for documents in a collection group. * @warning CANNOT access document ID variables, or the actual contents of each document that will be listed * To limit which documents can be listed, add an allow-all rule here, and configure `allowGetIf`. */ allowCollectionGroupListIf(rule: Rule): this; _transposeRuleField(resourcePath: string, fieldRuleResource: FieldRuleReference | string): string; _transposeCondition(resourcePath: string, condition: RuleCondition): string; _transposeRule(resourcePath: string, rule: Rule): RuleStringConditions; _getCollectionGroups(): Collection[]; _build(): BuildResult; _buildCollectionGroup(): (string | (string | BuildResult)[])[]; } export declare function collection>, COLLECTIONS extends CollectionArray>(name: NAME, documentIdVar: string | undefined, fields: FIELDS, collections: COLLECTIONS): Collection;