/** * A callback for a [[DynamicValue]] */ export declare type Listener = (value: T) => void; /** * A function to unsubscribe from a [[DynamicValue]] */ export declare type Unsubscriber = () => void; /** * A DynamicValue holds a value that can potentially change and is observable * @template T The type of the value that is held */ export interface DynamicValue { /**Metadata holding the class name of the DynamicValue, so it can be mapped back to the class from a JSON */ __variant__: string; name: string | void; /**A function to subscribe to the value that is held by the DynamicValue*/ onValue: (listener: Listener) => Unsubscriber; getValue: () => Promise; } export declare class DynamicValue { /** * Maps a JSON object to an instance of its class */ static fromJSON(json: any): any; }