import { SyncChunk } from '../../sdk/WalletStorage.interfaces'; import { EntityTimeStamp } from '../../sdk/types'; /** * Shared entity-validation helpers used by both client-side storage remoting * (StorageClientBase / StorageMobile) and the server-side StorageServer. * * These helpers normalise records returned from remote calls or database queries: * - Coerce date strings / timestamps to `Date` objects. * - Replace `null` values with `undefined`. * - Replace `Uint8Array` / `Buffer` values with plain `number[]` arrays. */ export declare function validateDate(date: Date | string | number): Date; /** * Force uniform behaviour across database engines. * Use to process all individual records with timestamps retrieved from database. */ export declare function validateEntity(entity: T, dateFields?: string[]): T; /** * Force uniform behaviour across database engines. * Use to process all arrays of records with timestamps retrieved from database. * @returns input `entities` array with contained values validated. */ export declare function validateEntities(entities: T[], dateFields?: string[]): T[]; /** * Validate all entity arrays within a `SyncChunk` received from a remote storage call. * Normalises timestamps, nulls, and binary fields in-place. */ export declare function validateSyncChunkEntities(r: SyncChunk): SyncChunk; //# sourceMappingURL=entityValidationHelpers.d.ts.map