import { ArraySet } from './array'; export * from './tree'; export declare type PropertyKey = string | number | symbol; export declare type OperationType = 'add' | 'delete' | 'clear' | 'set' | 'get' | 'iterate' | 'has'; export interface IOperation { target?: any; oldTarget?: any; key?: PropertyKey; value?: any; oldValue?: any; type?: OperationType; receiver?: any; } export interface IChange { key?: PropertyKey; path?: ObservablePath; value?: any; oldValue?: any; type?: OperationType; } export interface IEffectQueueItem { dispose?: void | Dispose; deps?: any[]; } export interface IMemoQueueItem { value?: any; deps?: any[]; } export interface IVisitor { target?: Target; key?: PropertyKey; value?: Value; } export declare type Annotation = (...args: any[]) => any; export declare type Annotations = { [key in keyof T]?: Annotation; }; export declare type ObservableListener = (operation: IOperation) => void; export declare type ObservablePath = Array; export declare type Dispose = () => void; export declare type Effect = () => void | Dispose; export declare type Reaction = ((...args: any[]) => any) & { _boundary?: number; _name?: string; _isComputed?: boolean; _dirty?: boolean; _context?: any; _disposed?: boolean; _property?: PropertyKey; _computesSet?: ArraySet; _reactionsSet?: ArraySet; _scheduler?: (reaction: Reaction) => void; _memos?: { queue: IMemoQueueItem[]; cursor: number; }; _effects?: { queue: IEffectQueueItem[]; cursor: number; }; }; export declare type ReactionsMap = Map>; export interface IReactionOptions { name?: string; equals?: (oldValue: T, newValue: T) => boolean; fireImmediately?: boolean; } export declare type BindFunction any> = (callback?: F, context?: any) => F; export declare type BoundaryFunction = any>(fn?: F) => ReturnType; export interface IBoundable { bound?: any>(callback: T, context?: any) => T; } export interface IAction extends IBoundable { (callback?: () => T): T; scope?: ((callback?: () => T) => T) & IBoundable; } export interface IBatch extends IAction { endpoint?: (callback?: () => void) => void; }