import {Action} from "./Action";
import Signal from "../../events/signal/Signal";

export class ActionProcessor<CTX, MD> {
    constructor(context: CTX)

    mark(description: MD): void

    getMarkCount(): number

    getMarkDescription(index: number): Readonly<MD>

    readonly onMarkAdded: Signal<MD>
    readonly onMarkRemoved: Signal<MD>

    undo(): Promise<void>

    redo(): Promise<void>

    navigateTo(mark: MD): Promise<boolean>

    doMany(actions: Action<CTX>[]): Promise<void>

    do(action: Action<CTX>): Promise<void>

    clear(): void
}
