import type { EmptyObject } from '../../../Types';
import type { ContextWithState } from '../../Types';
import type { StateAtom } from './Types';
declare function add<T>(arr: T[], ...values: T[]): boolean;
declare function addIfNew<T>(arr: T[], ...values: T[]): boolean;
declare function insert<T>(arr: T[], index: number, ...values: [T, ...T[]]): boolean;
declare function insertSorted<T>(arr: T[], getValue: (val: T) => number, ...values: T[]): boolean;
declare function remove<T>(arr: T[], ...values: T[]): boolean;
declare function clear<T>(arr: T[]): boolean;
declare function set<T>(arr: T[], newArr: T[]): boolean;
export type ArrayAtom<Atom> = StateAtom<Atom[], {
    add: typeof add<Atom>;
    insert: typeof insert<Atom>;
    insertSorted: typeof insertSorted<Atom>;
    remove: typeof remove<Atom>;
    clear: typeof clear<Atom>;
    set: typeof set<Atom>;
    addIfNew: typeof addIfNew<Atom>;
}>;
export declare const createArrayAtom: <ArrayType extends EmptyObject>(context: ContextWithState, initialValue?: ArrayType[]) => ArrayAtom<ArrayType>;
export {};
