/** * Represents a function used to order two values `a` and `b`. When `a` is * ordered before `b`, it should return a negative number. When `a` and `b` * are equivalent in order, it should return 0. When `a` is after `b`, it * should return a positive number. */ export type CompareFunction = (a: V, b: V) => number; /** * A class used to determine ordering and equality of values of a type. * Use one of the static comparisons to do normal or reverse ordering of * string and numeric primitives, or a custom {@link CompareFunction} for * object types and other special orderings. */ export declare class Comparator { #private; constructor(compareFn?: CompareFunction); static lexicalCompare(a: V, b: V): 0 | 1 | -1; static reverseLexicalCompare(a: V, b: V): number; static numericCompare(a: V, b: V): number; static reverseNumericCompare(a: V, b: V): number; eq(a: V, b: V): boolean; gt(a: V, b: V): boolean; gte(a: V, b: V): boolean; lt(a: V, b: V): boolean; lte(a: V, b: V): boolean; }