import { KeyIndex } from '@phensley/cldr-types'; /** * Inverse mapping of a key to its index in an array. * * @public */ export declare class KeyIndexImpl implements KeyIndex { readonly keys: T[]; readonly index: { [P in T]: number; }; readonly size: number; readonly last: number; constructor(keys: T[]); get(key: T): number; } /** * @public */ export interface Digits { readonly type: 'digits'; readonly name: string; readonly dim0: string; readonly values: number[]; } /** * @public */ export interface Field { readonly type: 'field'; readonly name: string; } /** * @public */ export interface Origin { readonly type: 'origin'; readonly block: Scope[]; readonly indices: { [x: string]: KeyIndex; }; getIndex(name: string): KeyIndex; getValues(name: string): string[]; } /** * @public */ export declare class OriginImpl implements Origin { readonly block: Scope[]; readonly indices: { [x: string]: KeyIndex; }; readonly type = "origin"; constructor(block: Scope[], indices: { [x: string]: KeyIndex; }); getIndex(name: string): KeyIndex; getValues(name: string): string[]; } /** * @public */ export interface Scope { readonly type: 'scope'; readonly name: string; readonly identifier: string; readonly block: Instruction[]; } /** * @public */ export interface ScopeMap { readonly type: 'scopemap'; readonly name: string; readonly fields: string; readonly block: Instruction[]; } /** * @public */ export interface Vector { readonly type: 'vector'; readonly name: string; readonly dims: string[]; } /** * @public */ export type Instruction = Digits | Field | Origin | Scope | ScopeMap | Vector; /** * @internal */ export declare const digits: (name: string, dim0: string, values: number[]) => Digits; /** * @internal */ export declare const field: (name: string) => Field; /** * @internal */ export declare const origin: (block: Scope[], indices: { [x: string]: KeyIndex; }) => Origin; /** * @internal */ export declare const scope: (name: string, identifier: string, block: Instruction[]) => Scope; /** * @internal */ export declare const scopemap: (name: string, fields: string, block: Instruction[]) => ScopeMap; /** * @internal */ export declare const vector: (name: string, dims: string[]) => Vector;