import { LegoProvingKey } from './legosnark'; export declare function convertDateToTimestamp(v: Date | string | unknown): number; export declare function isEmptyObject(obj: any): boolean; export declare function jsonObjToUint8Array(json: string): Uint8Array; export declare function getUint8ArraysFromObject(obj: Record, keys: string[]): Uint8Array[]; export declare function bytesToChallenge(bytes: Uint8Array): Uint8Array; export declare function isNumberBiggerThanNBits(num: number, bits: number): boolean; /** * Throws an error if the given number takes more bits than expected. * @param num * @param size - expected size in bits */ export declare function ensurePositiveIntegerOfSize(num: number, size: number): void; export declare function randomFieldElement(seed?: Uint8Array): Uint8Array; /** * Takes an object, nested or otherwise and flattens it to list. Returns 2 arrays, 1st array contains keys in alphabetical * sorted order and 2nd contains the values in the order of the keys. Both arrays have same size. Nested keys have their * parent key name prefixed with a dot, eg for key `lat` in `{location: {lat: 25.01, long: 30.02} }`, it becomes `location.lat` * @param obj * @param flattenOptions */ export declare function flattenObjectToKeyValuesList(obj: object, flattenOptions?: undefined): [string[], unknown[]]; export declare function isPositiveInteger(n: unknown): boolean; export declare function bytearrayToHex(b: Uint8Array): string; export declare function hexToBytearray(h: string): Uint8Array; export declare function bytearrayToBase64(b: Uint8Array): string; export declare function base64ToBytearray(base64Str: string): Uint8Array; export declare function bytearrayToBase58(b: Uint8Array): string; export declare function base58ToBytearray(base58Str: string): Uint8Array; export declare function areArraysEqual(arr1: string[] | number[] | boolean[], arr2: string[] | number[] | boolean[]): boolean; export declare function getProvingAndVerifiyingKeyBytes(provingKey: LegoProvingKey, returnUncompressed: boolean): [Uint8Array, Uint8Array]; /** * Convert little-endian bytearray to BigInt * @param arr * @param readTill * @returns */ export declare function fromLeToBigInt(arr: Uint8Array, readTill?: number): bigint; export declare function areUint8ArraysEqual(arr1: Uint8Array, arr2: Uint8Array): boolean; //# sourceMappingURL=util.d.ts.map