import { z } from 'zod'; /** * Error indicating violations of field-level constraints */ export declare class ValidationError { readonly message: string; constructor(message: string); } /** * Validate the given data with the given zod schema (for field-level constraints) */ export declare function validate(validator: z.ZodType, data: unknown): void; /** * Check if the given object has all the given fields, not null or undefined * @param obj * @param fields * @returns */ export declare function hasAllFields(obj: any, fields: string[]): boolean; /** * Check if the given objects have equal values for the given fields. Returns * false if either object is nullish or is not an object. */ export declare function allFieldsEqual(obj1: any, obj2: any, fields: string[]): boolean;