UNPKG

@playcanvas/observer

Version:

Generic implementation of the observer pattern

33 lines (32 loc) 808 B
import { Events } from './events'; /** * The ObserverHistory module provides a mechanism for tracking changes to an Observer object and * storing them in a history stack. */ declare class ObserverHistory extends Events { item: any; private _history; private _enabled; private _prefix; private _combine; private _selfEvents; /** * @param args - Arguments */ constructor(args?: { item?: any; history?: any; enabled?: boolean; prefix?: string; combine?: boolean; }); private _initialize; destroy(): void; set enabled(value: boolean); get enabled(): boolean; set prefix(value: string); get prefix(): string; set combine(value: boolean); get combine(): boolean; } export { ObserverHistory };