import { type ApplicationService } from '@adonisjs/core/types'; import { type Component } from './component.js'; import ComponentContext from './component_context.js'; import { type Checksum } from './checksum.js'; import { type Synth } from '../index.js'; import type { ComponentSnapshot } from './types.js'; /** * Owns synthesizer lookup, the dehydrate/hydrate value pipeline, and * snapshot assembly for `Livewire`. Extracted from the `Livewire` god * object to give this cluster of responsibilities its own file and direct * test coverage — see the design doc for the full rationale. */ export declare class SnapshotManager { private app; private checksum; private getSynthesizers; constructor(app: ApplicationService, checksum: Checksum, getSynthesizers: () => Array); getSynthesizerByKey(key: string, context: ComponentContext, path: string): Synth; getSynthesizerByTarget(target: any, context: ComponentContext, path: string): Synth; propertySynth(keyOrTarget: any, context: ComponentContext, path: string): Synth; /** * Try to get a synthesizer for the target, return null if not found * PHP parity: propertySynth (but doesn't throw) */ tryGetSynthesizerByTarget(target: any, context: ComponentContext, path: string): Synth | null; dehydrate(target: any, context: ComponentContext, path: string): Promise; dehydrateProperties(component: Component, context: ComponentContext): Promise<{}>; hydrate(data: any, context: ComponentContext, path: string): Promise; hydrateProperties(component: Component, data: Record, context: ComponentContext): Promise; snapshot(component: Component, context?: ComponentContext | null): Promise; }