import { type StructureRecord, type StructureSource } from "#structures/source"; /** * The source directory the fetcher writes. */ export declare const NGA_WPI_SOURCE_ID = "nga-wpi"; /** * The file the fetcher writes, under the publisher's own name. */ export declare const NGA_WPI_FILENAME = "UpdatedPub150.csv"; /** * The columns this module reads, as `readCSVRecords` normalizes the publisher's * headers (`World Port Index Number` → `world_port_index_number`). */ export declare const NGA_WPI_COLUMNS: readonly ["world_port_index_number", "main_port_name", "country_code", "latitude", "longitude"]; /** * The GENC short country spellings that the codex's country lookup doesn't hold, * mapped to their ISO 3166-1 alpha-2 codes. * * GENC is the US Government's profile of ISO 3166, and it spells several countries its own way * (`Burma`, `Congo (Kinshasa)`) and names some territories ISO 3166 groups under one code: * Johnson Atoll, Midway and Wake Island are UM, and Svalbard is SJ. */ export declare const WPI_GENC_COUNTRY_NAMES: Readonly>; /** * One CSV row, keyed by the normalized column names. */ export type NGAWPIRow = Readonly>; /** * The ISO 3166-1 alpha-2 code of a row's GENC country name. * * @throws When neither the codex's country lookup nor {@linkcode WPI_GENC_COUNTRY_NAMES} * holds the name, so a port is never stamped with a guessed country. */ export declare function wpiCountryCode(name: string): string; /** * One CSV row as a structure record. * * @throws When the row has no World Port Index number or its country can't be read. */ export declare function wpiStructureRecord(row: NGAWPIRow): StructureRecord; /** * NGA's World Port Index. */ export declare const ngaWorldPortIndexStructures: StructureSource; //# sourceMappingURL=nga-wpi.d.ts.map