import { BehaviorSubject } from 'rxjs';
import { BasicModel } from './basic';
import { ValidateOption } from '../validate';
import { INormalizeBeforeSubmit } from './field';
import type { BasicBuilder } from '../builders/basic';
import { IModel } from './base';
import { FIELD_ARRAY_ID } from './is';
import type { FieldArrayBuilder } from '../builders';
declare class FieldArrayModel<Item, Child extends IModel<Item> = IModel<Item>> extends BasicModel<readonly Item[]> {
    private readonly defaultValue;
    [FIELD_ARRAY_ID]: boolean;
    protected readonly _displayName = "FieldArrayModel";
    readonly children$: BehaviorSubject<Child[]>;
    owner: IModel<any> | null;
    readonly builder?: FieldArrayBuilder<BasicBuilder<Item, Child>>;
    private _valid$?;
    private _value$?;
    private readonly invalidModels;
    private readonly mapModelToSubscriptions;
    private readonly childFactory;
    normalizeBeforeSubmit: INormalizeBeforeSubmit<Item[], any>;
    constructor(childBuilder: BasicBuilder<Item, Child> | null, defaultValue: readonly Item[]);
    get value(): readonly Item[];
    get value$(): BehaviorSubject<readonly Item[]>;
    get valid$(): BehaviorSubject<boolean>;
    _getValue$(shouldWarn?: boolean): BehaviorSubject<readonly Item[]>;
    _getValid$(shouldWarn?: boolean): BehaviorSubject<boolean>;
    reset(): void;
    clear(): void;
    clearError(): void;
    get children(): ReadonlyArray<Child>;
    get(index: number): Child;
    getRawValue(): Item[];
    getSubmitValue(): any;
    patchValue(value: Item[]): void;
    initialize(values: Item[]): void;
    push(...models: Child[]): number;
    push(...values: Item[]): number;
    pop(): Child;
    shift(): Child;
    unshift(...models: Child[]): number;
    unshift(...values: Item[]): number;
    splice(start: number, deleteCount: number, ...models: readonly Child[]): Child[];
    splice(start: number, deleteCount: number, ...values: readonly Item[]): Child[];
    filter(predicate: (item: Child, index: number, array: Child[]) => boolean): this;
    sort(compareFn: (a: Child, b: Child) => number): this;
    validate(option?: ValidateOption): Promise<any>;
    pristine(): boolean;
    dirty(): boolean;
    touched(): boolean;
    dispose(): void;
    private _linkChild;
    private _initValue$;
    private _initValid$;
    private _initUnsubscribeChild;
    private _getValue;
    private _subscribeChild;
    private _subscribeChildModel;
    private _subscribeObservable;
    private _unsubscribeChild;
    private _disposeChild;
    private _buildChild;
    private _unsubscribeModel;
}
export { FieldArrayModel };
