import { CryptographicParameters } from '../types.js'; import type * as ContractAddress from '../types/ContractAddress.js'; import { AttributeType, StatementAttributeType, TimestampAttribute } from './types.js'; export type VerifyWeb3IdCredentialSignatureInput = { globalContext: CryptographicParameters; signature: string; values: Record; randomness: Record; holder: string; issuerPublicKey: string; issuerContract: ContractAddress.Type; }; /** * Compares a and b as field elements. * if a < b then compareStringAttributes(a,b) = -1; * if a == b then compareStringAttributes(a,b) = 0; * if a > b then compareStringAttributes(a,b) = 1; */ export declare function compareStringAttributes(a: string, b: string): number; /** * Given a string attribute value and a range [lower, upper[, return whether value is in the range, when converted into field elements. */ export declare function isStringAttributeInRange(value: string, lower: string, upper: string): boolean; /** * Converts a timestamp attribute to a Date. * @param attribute the timestamp attribute * @returns a Date representing the timestamp */ export declare function timestampToDate(attribute: TimestampAttribute): Date; /** * Converts a Date to a timestamp attribute. * @param value the date to convert to an attribute * @returns the timestamp attribute for the provided date */ export declare function dateToTimestampAttribute(value: Date): TimestampAttribute; /** * Converts a statement attribute to an attribute. Statement attributes allow * for Date which are mapped into timestamp attributes. All other attribute * types are mapped one-to-one. * @param statementAttribute the statement attribute to map * @returns the mapped attribute type */ export declare function statementAttributeTypeToAttributeType(statementAttribute: StatementAttributeType): AttributeType; /** * Parses a {@linkcode Date} from a string containing a year and month in the form "YYYYMM". * * @param yearMonth - The string to parse * @returns the parsed {@linkcode Date} * @throws if the date cannot be parsed */ export declare function parseYearMonth(yearMonth: string): Date;