/** * Mnemonist PassjoinIndex Typings * ================================ */ type LevenshteinDistanceFunction = (a: T, b: T) => number; export default class PassjoinIndex implements Iterable { // Members size: number; // Constructor constructor(levenshtein: LevenshteinDistanceFunction, k: number); // Methods add(value: T): this; search(query: T): Set; clear(): void; forEach(callback: (value: T, index: number, self: this) => void, scope?: any): void; values(): IterableIterator; [Symbol.iterator](): IterableIterator; inspect(): any; // Statics static from( iterable: Iterable | {[key: string]: I}, levenshtein: LevenshteinDistanceFunction, k: number ): PassjoinIndex; } export function countKeys(k: number, s: number): number; export function comparator(a: T, b: T): number; export function partition(k: number, l: number): Array<[number, number]>; export function segments(k: number, string: T): Array; export function segmentPos(k: number, i: number, string: T): number; export function multiMatchAwareInterval( k: number, delta: number, i: number, s: number, pi: number, li: number ): [number, number]; export function multiMatchAwareSubstrings( k: number, string: T, l: number, i: number, pi: number, li: number ): Array;