import type { Inspectable } from "./Inspectable.js"; import type { Pipeable } from "./Pipeable.js"; declare const TypeId: unique symbol; /** * @since 2.0.0 * @category symbol */ export type TypeId = typeof TypeId; /** * @since 2.0.0 * @category model */ export interface MutableList extends Iterable, Pipeable, Inspectable { readonly [TypeId]: TypeId; } /** * Creates an empty `MutableList`. * * @since 2.0.0 * @category constructors */ export declare const empty: () => MutableList; /** * Creates a new `MutableList` from an iterable collection of values. * * @since 2.0.0 * @category constructors */ export declare const fromIterable: (iterable: Iterable) => MutableList; /** * Creates a new `MutableList` from the specified elements. * * @since 2.0.0 * @category constructors */ export declare const make: (...elements: ReadonlyArray) => MutableList; /** * Returns `true` if the list contains zero elements, `false`, otherwise. * * @since 2.0.0 * @category getters */ export declare const isEmpty: (self: MutableList) => boolean; /** * Returns the length of the list. * * @since 2.0.0 * @category getters */ export declare const length: (self: MutableList) => number; /** * Returns the last element of the list, if it exists. * * @since 2.0.0 * @category getters */ export declare const tail: (self: MutableList) => A | undefined; /** * Returns the first element of the list, if it exists. * * @since 2.0.0 * @category getters */ export declare const head: (self: MutableList) => A | undefined; /** * Executes the specified function `f` for each element in the list. * * @since 2.0.0 * @category traversing */ export declare const forEach: { /** * Executes the specified function `f` for each element in the list. * * @since 2.0.0 * @category traversing */ (f: (element: A) => void): (self: MutableList) => void; /** * Executes the specified function `f` for each element in the list. * * @since 2.0.0 * @category traversing */ (self: MutableList, f: (element: A) => void): void; }; /** * Removes all elements from the doubly-linked list. * * @since 2.0.0 */ export declare const reset: (self: MutableList) => MutableList; /** * Appends the specified element to the end of the `MutableList`. * * @category concatenating * @since 2.0.0 */ export declare const append: { /** * Appends the specified element to the end of the `MutableList`. * * @category concatenating * @since 2.0.0 */ (value: A): (self: MutableList) => MutableList; /** * Appends the specified element to the end of the `MutableList`. * * @category concatenating * @since 2.0.0 */ (self: MutableList, value: A): MutableList; }; /** * Removes the first value from the list and returns it, if it exists. * * @since 0.0.1 */ export declare const shift: (self: MutableList) => A | undefined; /** * Removes the last value from the list and returns it, if it exists. * * @since 0.0.1 */ export declare const pop: (self: MutableList) => A | undefined; /** * Prepends the specified value to the beginning of the list. * * @category concatenating * @since 2.0.0 */ export declare const prepend: { /** * Prepends the specified value to the beginning of the list. * * @category concatenating * @since 2.0.0 */ (value: A): (self: MutableList) => MutableList; /** * Prepends the specified value to the beginning of the list. * * @category concatenating * @since 2.0.0 */ (self: MutableList, value: A): MutableList; }; export {}; //# sourceMappingURL=MutableList.d.ts.map