import type { ElementSymbol } from '../../element'; import type { Vec3 } from '../../math'; import * as math from '../../math'; import type { AnyStructure, BondOrder, LatticeType, Pbc, Site, StructureBond } from '..'; export declare const reset_parse_diagnostics: () => void; export declare const diag_error: (message: string, error?: unknown) => void; export declare const diag_warn: (message: string) => void; export declare const get_parse_errors: () => string[]; export declare const guard_parse: (format: string, parse: () => T | null) => T | null; export declare const parse_float_token: (token: string | undefined) => number; export declare class LineScanner { private starts; private ends; private values; private line; count: number; scan(line: string, from?: number, to?: number): number; str(token_idx: number): string; token_length(token_idx: number): number; num(token_idx: number): number; } export declare const parse_coordinate: (token: string) => number; export declare const is_num_token: (token: string, integer?: boolean) => boolean; export declare const row_tokens: (row: string, min_tokens: number, expected: string) => string[] | null; export declare const vec3_from_values: (values: unknown, context: string) => Vec3; export declare const matrix3x3_from_rows: (rows: unknown, context: string) => math.Matrix3x3; export declare const count_elements: (elements: readonly string[]) => Record; export declare const read_cell_params: (lines: readonly string[], dialect: `CIF` | `mmCIF`) => number[] | null; export declare const cell_params_to_matrix: (params: readonly number[]) => math.Matrix3x3; export declare const is_placeholder_cell: (params: readonly number[]) => boolean; export declare const drop_placeholder_cell: (params: readonly number[], format: string, cell_name: string) => readonly number[] | null; export declare const cell_frame: (params: readonly number[] | null, context: string) => { lattice_matrix: math.Matrix3x3 | null; to_frac: (xyz: Vec3) => Vec3; }; export declare const make_lattice: (matrix: math.Matrix3x3, pbc?: Pbc) => LatticeType; export declare const parsed_result: (sites: Site[], bonds?: readonly StructureBond[], lattice_matrix?: math.Matrix3x3 | null) => AnyStructure; export declare const capitalize_symbol: (raw: string) => string; export declare const FALLBACK_ELEMENTS: readonly ["H", "He", "Li", "Be", "B", "C", "N", "O", "F", "Ne"]; export declare function validate_element_symbol(symbol: string, index: number): ElementSymbol; export declare const element_from_candidates: (candidates: readonly (string | undefined)[], atom_idx: number) => ElementSymbol; export declare const cart_to_frac_with_fallback: (matrix: math.Matrix3x3, opts?: { axis_lengths?: Vec3; context?: string; warn?: (message: string) => void; }) => { convert: (xyz: Vec3) => Vec3; exact: boolean; }; export type RawBond = { atom_id_1: number; atom_id_2: number; order: BondOrder; }; export declare const record_atom_id: (site_idx_by_atom_id: Map, atom_id: number, site_idx: number) => void; export declare const resolve_bonds: (raw_bonds: readonly RawBond[], site_idx_by_atom_id: ReadonlyMap, context: string) => StructureBond[]; export declare const parse_cif_uncertain_number: (token: string) => number | null; export declare function iter_cif_loops(lines: string[]): Generator<{ headers: string[]; data_start: number; }>; export declare const split_cif_tokens: (line: string) => string[];