import type { EntityData, EntityMetadata, EntityProperty, IHydrator } from '../typings.js';
import type { EntityFactory } from '../entity/EntityFactory.js';
import type { Platform } from '../platforms/Platform.js';
import type { MetadataStorage } from '../metadata/MetadataStorage.js';
import type { Configuration } from '../utils/Configuration.js';
/** Abstract base class for hydrating entity instances from raw database data. */
export declare abstract class Hydrator implements IHydrator {
  protected readonly metadata: MetadataStorage;
  protected readonly platform: Platform;
  protected readonly config: Configuration;
  protected running: boolean;
  constructor(metadata: MetadataStorage, platform: Platform, config: Configuration);
  /**
   * @inheritDoc
   */
  hydrate<T extends object>(
    entity: T,
    meta: EntityMetadata<T>,
    data: EntityData<T>,
    factory: EntityFactory,
    type: 'full' | 'reference',
    newEntity?: boolean,
    convertCustomTypes?: boolean,
    schema?: string,
    parentSchema?: string,
  ): void;
  /**
   * @inheritDoc
   */
  hydrateReference<T extends object>(
    entity: T,
    meta: EntityMetadata<T>,
    data: EntityData<T>,
    factory: EntityFactory,
    convertCustomTypes?: boolean,
    schema?: string,
    parentSchema?: string,
  ): void;
  /** Returns whether the hydrator is currently in the middle of hydrating an entity. */
  isRunning(): boolean;
  protected getProperties<T extends object>(meta: EntityMetadata<T>, type: 'full' | 'reference'): EntityProperty<T>[];
  protected hydrateProperty<T extends object>(
    entity: T,
    prop: EntityProperty<T>,
    data: EntityData<T>,
    factory: EntityFactory,
    newEntity?: boolean,
    convertCustomTypes?: boolean,
  ): void;
}
