import { ObservableState } from './observableState'; export declare class StateStreamRegistry { streams: Map>; started: boolean; /** * Register a stream to this stream registry * * If the registry has already been started, the registered stream will also be * started. * * Before the registry has started, an error will be thrown if the stream name * has already been used. * * @param stream The stream to register */ register(stream: ObservableState): void; /** * Start the registered reduced state streams. * * This causes the streams to actually start reducing over the action stream. * * Streams registered after this will also be started. * * If this is called twice without `stopReducing` being called in between, an * error will be thrown. * * @param action$ The action stream the streams should reduce over * @param states States to initialize the streams with, as returned by * `getStates` */ startReducing(): void; /** * Stops all the registered reduced state streams. * * This will call `unsubscribe` on all the streams. After this, all access to * the `.state` properties will throw exceptions. `getStates` can not be * called after `stopReducing` because of this. */ stopReducing(): void; } export declare const stateStreamRegistry: StateStreamRegistry;