import 'reflect-metadata'; import type { Constructor } from '@cratis/fundamentals'; import type { IClientArtifactsProvider } from '../artifacts/IClientArtifactsProvider.js'; import { ReadModelScenarioGivenBuilder } from './ReadModelScenarioGivenBuilder.js'; import type { EventScenario } from './EventScenario.js'; import type { AppendOptions } from '../eventSequences/AppendOptions.js'; import type { ReactorScenario } from './ReactorScenario.js'; type ScenarioArtifacts = Pick & Partial>; /** * Folds seeded events through a reducer or a validated flat projection, without a Chronicle kernel. * Observer scheduling, storage, migrations, and compliance are not simulated. * Supply an artifact catalog to isolate a scenario from process-wide decorator discovery. */ export declare class ReadModelScenario { private readonly _processor; private readonly _modelName; private readonly _events; private _results; private _observed; /** Selects the reducer (when present) or a single applicable compiled projection. */ constructor(readModelType: Constructor, artifacts?: ScenarioArtifacts); /** Fluent entry point for event history. */ get given(): ReadModelScenarioGivenBuilder; /** Returns the sole materialized model, or null when no model exists. */ get instance(): Promise; /** Returns the model for one source, or null if no handler created it or it was deleted. */ instanceForEventSourceId(id: string): Promise; /** Distinguishes a model removed by a reducer from one never created. */ wasDeletedForEventSourceId(id: string): Promise; /** * Reads the committed history of an EventScenario or ReactorScenario instead of seeded events. * Every read replays that shared sequence as it is at the time of the read. */ observe(source: EventScenario | ReactorScenario): this; /** Collects events for a source; subsequent reads replay the complete seeded history. */ collectEventsFor(id: string, events: readonly object[], options?: AppendOptions): void; private process; private replay; private observedEvents; private mixedHistory; } export {}; //# sourceMappingURL=ReadModelScenario.d.ts.map