UNPKG

@altostra/core

Version:

Core library for shared types and logic

30 lines (29 loc) 849 B
import type { Alphabet } from "./common"; /** * `UnicodeSubsetAlphabet` parameters */ export interface UnicodeSubsetAlphabetParams { start?: number | string; end?: number | string; } /** * And alphabet which is build from a straight (without skips) subset from the Unicode * characters set */ export declare class UnicodeSubsetAlphabet implements Alphabet { #private; /** * The entire Unicode characters set alphabet */ static readonly unicode: UnicodeSubsetAlphabet; /** * The ASCII characters set alphabet */ static readonly ascii: UnicodeSubsetAlphabet; readonly length: number; constructor({ start, end, }?: UnicodeSubsetAlphabetParams); getAt(index: number): string; indexOf(char: string): number; [Symbol.iterator](): Iterator<string>; has(char: string): boolean; }