@urban-toolkit/autk-db 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -0
- package/dist/autk-db.js +6356 -0
- package/dist/autk-db.js.map +1 -0
- package/dist/basedecoder-DaTXO39b.js +62 -0
- package/dist/basedecoder-DaTXO39b.js.map +1 -0
- package/dist/deflate-DT_oTgqy.js +12 -0
- package/dist/deflate-DT_oTgqy.js.map +1 -0
- package/dist/duckdb-browser-eh.worker.js +14 -0
- package/dist/duckdb-browser-mvp.worker.js +14 -0
- package/dist/duckdb-eh.wasm +0 -0
- package/dist/duckdb-mvp.wasm +0 -0
- package/dist/globals-QF85DtAk.js +574 -0
- package/dist/globals-QF85DtAk.js.map +1 -0
- package/dist/jpeg-DckFSoVK.js +522 -0
- package/dist/jpeg-DckFSoVK.js.map +1 -0
- package/dist/lerc-BCdGEeLp.js +758 -0
- package/dist/lerc-BCdGEeLp.js.map +1 -0
- package/dist/lzw-B3twMQgz.js +73 -0
- package/dist/lzw-B3twMQgz.js.map +1 -0
- package/dist/packbits-pbHfk2l8.js +24 -0
- package/dist/packbits-pbHfk2l8.js.map +1 -0
- package/dist/pako.esm-Crx1NgSq.js +1447 -0
- package/dist/pako.esm-Crx1NgSq.js.map +1 -0
- package/dist/raw-BpEIWqGM.js +11 -0
- package/dist/raw-BpEIWqGM.js.map +1 -0
- package/dist/src/config/duckdb.d.ts +8 -0
- package/dist/src/main.d.ts +22 -0
- package/dist/src/shared/HttpCache.d.ts +55 -0
- package/dist/src/shared/clusterIntersectingFeatures.d.ts +11 -0
- package/dist/src/shared/consts.d.ts +4 -0
- package/dist/src/shared/interfaces.d.ts +44 -0
- package/dist/src/shared/osm-tag-definitions.d.ts +13 -0
- package/dist/src/spatial/SpatialDb.d.ts +264 -0
- package/dist/src/spatial/index.d.ts +5 -0
- package/dist/src/spatial/shared/use-cases/drop-table/DropTableUseCase.d.ts +25 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-area/GetBoundingBoxFromAreaUseCase.d.ts +16 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-area/interfaces.d.ts +6 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-layer/GetBoundingBoxFromLayerUseCase.d.ts +19 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-layer/interfaces.d.ts +6 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-layer/queries.d.ts +1 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-osm/GetBoundingBoxFromOsmUseCase.d.ts +19 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-osm/interfaces.d.ts +4 -0
- package/dist/src/spatial/shared/use-cases/get-bounding-box-from-osm/queries.d.ts +1 -0
- package/dist/src/spatial/shared/use-cases/transform-bounding-box-coordinates/TransformBoundingBoxCoordinatesUseCase.d.ts +20 -0
- package/dist/src/spatial/shared/use-cases/transform-bounding-box-coordinates/interfaces.d.ts +9 -0
- package/dist/src/spatial/shared/use-cases/transform-bounding-box-coordinates/queries.d.ts +11 -0
- package/dist/src/spatial/shared/utils.d.ts +20 -0
- package/dist/src/spatial/use-cases/aggregate-building-layer/AggregateBuildingLayerUseCase.d.ts +12 -0
- package/dist/src/spatial/use-cases/assign-building-ids/AssignBuildingIdsUseCase.d.ts +21 -0
- package/dist/src/spatial/use-cases/build-heatmap/BuildHeatmapUseCase.d.ts +14 -0
- package/dist/src/spatial/use-cases/build-heatmap/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/build-heatmap/interfaces.d.ts +18 -0
- package/dist/src/spatial/use-cases/get-layer-geojson/GetLayerGeojsonUseCase.d.ts +11 -0
- package/dist/src/spatial/use-cases/get-layer-geojson/index.d.ts +1 -0
- package/dist/src/spatial/use-cases/get-layer-geojson/queries.d.ts +2 -0
- package/dist/src/spatial/use-cases/get-table-data/GetTableDataUseCase.d.ts +10 -0
- package/dist/src/spatial/use-cases/get-table-data/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/get-table-data/interfaces.d.ts +7 -0
- package/dist/src/spatial/use-cases/load-csv/LoadCsvUseCase.d.ts +13 -0
- package/dist/src/spatial/use-cases/load-csv/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-csv/interfaces.d.ts +12 -0
- package/dist/src/spatial/use-cases/load-csv/queries.d.ts +12 -0
- package/dist/src/spatial/use-cases/load-custom-layer/LoadCustomLayerUseCase.d.ts +13 -0
- package/dist/src/spatial/use-cases/load-custom-layer/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-custom-layer/interfaces.d.ts +13 -0
- package/dist/src/spatial/use-cases/load-custom-layer/queries.d.ts +3 -0
- package/dist/src/spatial/use-cases/load-geotiff/LoadGeoTiffUseCase.d.ts +12 -0
- package/dist/src/spatial/use-cases/load-geotiff/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-geotiff/interfaces.d.ts +33 -0
- package/dist/src/spatial/use-cases/load-grid-layer/LoadGridLayerUseCase.d.ts +17 -0
- package/dist/src/spatial/use-cases/load-json/LoadJsonUseCase.d.ts +12 -0
- package/dist/src/spatial/use-cases/load-json/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-json/interfaces.d.ts +11 -0
- package/dist/src/spatial/use-cases/load-json/queries.d.ts +11 -0
- package/dist/src/spatial/use-cases/load-layer/LoadLayerUseCase.d.ts +27 -0
- package/dist/src/spatial/use-cases/load-layer/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-layer/interfaces.d.ts +19 -0
- package/dist/src/spatial/use-cases/load-layer/osm-processing-config.d.ts +10 -0
- package/dist/src/spatial/use-cases/load-layer/queries.d.ts +12 -0
- package/dist/src/spatial/use-cases/load-osm-from-overpass-api/LoadOsmFromOverpassApiUseCase.d.ts +89 -0
- package/dist/src/spatial/use-cases/load-osm-from-overpass-api/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-osm-from-overpass-api/interfaces.d.ts +59 -0
- package/dist/src/spatial/use-cases/load-osm-from-overpass-api/queries.d.ts +2 -0
- package/dist/src/spatial/use-cases/load-osm-from-pbf/LoadOsmFromPbfUseCase.d.ts +39 -0
- package/dist/src/spatial/use-cases/load-osm-from-pbf/index.d.ts +1 -0
- package/dist/src/spatial/use-cases/load-osm-from-pbf/osm-pbf-parser.d.ts +28 -0
- package/dist/src/spatial/use-cases/osm-processing-pipeline/OsmProcessingPipeline.d.ts +67 -0
- package/dist/src/spatial/use-cases/polygonize-surface-layer/PolygonizeSurfaceLayerUseCase.d.ts +13 -0
- package/dist/src/spatial/use-cases/polygonize-surface-layer/index.d.ts +2 -0
- package/dist/src/spatial/use-cases/polygonize-surface-layer/interfaces.d.ts +4 -0
- package/dist/src/spatial/use-cases/polygonize-surface-layer/queries.d.ts +1 -0
- package/dist/src/spatial/use-cases/raw-query/RawQueryUseCase.d.ts +12 -0
- package/dist/src/spatial/use-cases/raw-query/errors.d.ts +6 -0
- package/dist/src/spatial/use-cases/raw-query/index.d.ts +3 -0
- package/dist/src/spatial/use-cases/raw-query/interfaces.d.ts +13 -0
- package/dist/src/spatial/use-cases/spatial-join/SpatialJoinUseCase.d.ts +22 -0
- package/dist/src/spatial/use-cases/spatial-join/errors.d.ts +7 -0
- package/dist/src/spatial/use-cases/spatial-join/interfaces.d.ts +22 -0
- package/dist/src/spatial/use-cases/spatial-join/queries.d.ts +24 -0
- package/dist/src/spatial/use-cases/update-table/UpdateTableUseCase.d.ts +41 -0
- package/dist/src/spatial/use-cases/update-table/index.d.ts +3 -0
- package/dist/src/spatial/use-cases/update-table/interfaces.d.ts +35 -0
- package/dist/src/spatial/use-cases/update-table/queries.d.ts +45 -0
- package/dist/webimage-OC9EEb5f.js +25 -0
- package/dist/webimage-OC9EEb5f.js.map +1 -0
- package/dist/zstd-rpfNjbfx.js +49 -0
- package/dist/zstd-rpfNjbfx.js.map +1 -0
- package/package.json +58 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { t as e } from "./basedecoder-DaTXO39b.js";
|
|
2
|
+
//#region node_modules/geotiff/dist-module/compression/raw.js
|
|
3
|
+
var t = class extends e {
|
|
4
|
+
decodeBlock(e) {
|
|
5
|
+
return e;
|
|
6
|
+
}
|
|
7
|
+
};
|
|
8
|
+
//#endregion
|
|
9
|
+
export { t as default };
|
|
10
|
+
|
|
11
|
+
//# sourceMappingURL=raw-BpEIWqGM.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"raw-BpEIWqGM.js","names":[],"sources":["../node_modules/geotiff/dist-module/compression/raw.js"],"sourcesContent":["import BaseDecoder from './basedecoder.js';\nexport default class RawDecoder extends BaseDecoder {\n /** @param {ArrayBuffer} buffer */\n decodeBlock(buffer) {\n return buffer;\n }\n}\n//# sourceMappingURL=raw.js.map"],"x_google_ignoreList":[0],"mappings":";;AACA,IAAqB,IAArB,cAAwC,EAAY;CAEhD,YAAY,GAAQ;AAChB,SAAO"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as duckdb from '@duckdb/duckdb-wasm';
|
|
2
|
+
/**
|
|
3
|
+
* Loads and instantiates a DuckDB database, with Node.js and browser support.
|
|
4
|
+
*
|
|
5
|
+
* @returns An instantiated `AsyncDuckDB` instance ready for connections.
|
|
6
|
+
* @throws If DuckDB WebAssembly fails to load or instantiate.
|
|
7
|
+
*/
|
|
8
|
+
export declare function loadDb(): Promise<duckdb.AsyncDuckDB>;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module AutkDb
|
|
3
|
+
* Public entry point for the `@urban-toolkit/autk-db` package.
|
|
4
|
+
*
|
|
5
|
+
* Re-exports the spatial database class, table types, and OSM tag definitions.
|
|
6
|
+
*/
|
|
7
|
+
export type { LayerType, BoundingBox } from 'autk-core';
|
|
8
|
+
export { PARKS_LEISURE_VALUES, PARKS_LANDUSE_VALUES, PARKS_NATURAL_VALUES, WATER_NATURAL_VALUES, WATER_FEATURE_VALUES, EXCLUDED_HIGHWAY_VALUES as EXCLUDED_ROAD_HIGHWAY_VALUES, EXCLUDED_BUILDING_VALUES, } from './shared/osm-tag-definitions';
|
|
9
|
+
export type { Layer, LoadLayerParams } from './spatial/use-cases/load-layer/interfaces';
|
|
10
|
+
export type { LoadGeoTiffParams } from './spatial/use-cases/load-geotiff';
|
|
11
|
+
export type { CommonTable, Table, OsmTable, LayerTable, CustomLayerTable, CsvTable, JsonTable, AnyTable, GridLayerTable, GeoTiffTable, Column } from './shared/interfaces';
|
|
12
|
+
export type { GetTableDataParams, GetTableDataOutput } from './spatial/use-cases/get-table-data';
|
|
13
|
+
export type { LoadingPhase, OnLoadingProgress, OsmLoadTimings, LayerLoadTimings, LoadOsmParams } from './spatial/use-cases/load-osm-from-overpass-api/interfaces';
|
|
14
|
+
export type { SpatialQueryParams, AggregateFunction } from './spatial/use-cases/spatial-join/interfaces';
|
|
15
|
+
export type { BuildHeatmapParams, HeatmapAggregateFunction } from './spatial/use-cases/build-heatmap/interfaces';
|
|
16
|
+
export type { LoadCsvParams } from './spatial/use-cases/load-csv/interfaces';
|
|
17
|
+
export type { LoadCustomLayerParams } from './spatial/use-cases/load-custom-layer/interfaces';
|
|
18
|
+
export type { LoadGridLayerParams } from './spatial/use-cases/load-grid-layer/LoadGridLayerUseCase';
|
|
19
|
+
export type { LoadJsonParams } from './spatial/use-cases/load-json/interfaces';
|
|
20
|
+
export type { RawQueryParams, RawQueryOutput } from './spatial/use-cases/raw-query/interfaces';
|
|
21
|
+
export type { UpdateTableParams, UpdateStrategy } from './spatial/use-cases/update-table/interfaces';
|
|
22
|
+
export * from './spatial';
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Simple HTTP cache using Browser Cache API with TTL support
|
|
3
|
+
*/
|
|
4
|
+
export declare class HttpCache<T = any> {
|
|
5
|
+
private cache;
|
|
6
|
+
private readonly cacheName;
|
|
7
|
+
private readonly ttl;
|
|
8
|
+
/**
|
|
9
|
+
* Creates an HTTP cache with the given name and TTL.
|
|
10
|
+
*
|
|
11
|
+
* @param cacheName Name of the cache storage.
|
|
12
|
+
* @param ttl Time to live in milliseconds (default: 24 hours).
|
|
13
|
+
* @throws Never throws.
|
|
14
|
+
*/
|
|
15
|
+
constructor(cacheName: string, ttl?: number);
|
|
16
|
+
/**
|
|
17
|
+
* Initializes the Cache API storage if available.
|
|
18
|
+
*
|
|
19
|
+
* @throws Never throws. Failures leave the cache as `null`.
|
|
20
|
+
*/
|
|
21
|
+
private init;
|
|
22
|
+
/**
|
|
23
|
+
* Returns cached data for a key, or `null` if missing or expired.
|
|
24
|
+
*
|
|
25
|
+
* @param key Cache key to look up.
|
|
26
|
+
* @returns Cached data or `null`.
|
|
27
|
+
* @throws Never throws. Errors are caught and return `null`.
|
|
28
|
+
*/
|
|
29
|
+
get(key: string): Promise<T | null>;
|
|
30
|
+
private toRequest;
|
|
31
|
+
/**
|
|
32
|
+
* Stores data in the cache with a current timestamp.
|
|
33
|
+
*
|
|
34
|
+
* @param key Cache key to store under.
|
|
35
|
+
* @param data Value to cache.
|
|
36
|
+
* @returns Nothing.
|
|
37
|
+
* @throws Never throws. Errors are silently caught.
|
|
38
|
+
*/
|
|
39
|
+
set(key: string, data: T): Promise<void>;
|
|
40
|
+
/**
|
|
41
|
+
* Deletes a specific key from the cache.
|
|
42
|
+
*
|
|
43
|
+
* @param key Cache key to remove.
|
|
44
|
+
* @returns Nothing.
|
|
45
|
+
* @throws Never throws. Errors are silently caught.
|
|
46
|
+
*/
|
|
47
|
+
delete(key: string): Promise<void>;
|
|
48
|
+
/**
|
|
49
|
+
* Clears all items from this cache.
|
|
50
|
+
*
|
|
51
|
+
* @returns Nothing.
|
|
52
|
+
* @throws Never throws. Errors are silently caught.
|
|
53
|
+
*/
|
|
54
|
+
clear(): Promise<void>;
|
|
55
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Geometry } from 'geojson';
|
|
2
|
+
/**
|
|
3
|
+
* Computes connected components (clusters) of intersecting geometries and returns
|
|
4
|
+
* a mapping from feature id to cluster id. The input array must contain an
|
|
5
|
+
* application-level identifier for each geometry. Cluster ids are stable only
|
|
6
|
+
* within a single invocation and start at 0.
|
|
7
|
+
*/
|
|
8
|
+
export declare function computeIntersectingClusterIds(items: Array<{
|
|
9
|
+
id: number | string;
|
|
10
|
+
geometry: Geometry | null | undefined;
|
|
11
|
+
}>): Map<string, number>;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { LayerType, BoundingBox } from 'autk-core';
|
|
2
|
+
export type { BoundingBox };
|
|
3
|
+
export { PARKS_LEISURE_VALUES, PARKS_LANDUSE_VALUES, PARKS_NATURAL_VALUES, WATER_NATURAL_VALUES, WATER_FEATURE_VALUES, EXCLUDED_HIGHWAY_VALUES as EXCLUDED_ROAD_HIGHWAY_VALUES, EXCLUDED_BUILDING_VALUES, } from './osm-tag-definitions';
|
|
4
|
+
export type GridLayerTable = CommonTable & {
|
|
5
|
+
source: 'user';
|
|
6
|
+
type: LayerType;
|
|
7
|
+
};
|
|
8
|
+
export type GeoTiffTable = CommonTable & {
|
|
9
|
+
source: 'geotiff';
|
|
10
|
+
type: 'raster';
|
|
11
|
+
};
|
|
12
|
+
export type Table = OsmTable | LayerTable | CsvTable | JsonTable | CustomLayerTable | GridLayerTable | GeoTiffTable | AnyTable;
|
|
13
|
+
export type OsmTable = CommonTable & {
|
|
14
|
+
source: 'osm';
|
|
15
|
+
type: 'pointset';
|
|
16
|
+
};
|
|
17
|
+
export type LayerTable = CommonTable & {
|
|
18
|
+
source: 'osm';
|
|
19
|
+
type: LayerType;
|
|
20
|
+
};
|
|
21
|
+
export type CustomLayerTable = CommonTable & {
|
|
22
|
+
source: 'geojson';
|
|
23
|
+
type: LayerType;
|
|
24
|
+
};
|
|
25
|
+
export type CsvTable = CommonTable & {
|
|
26
|
+
source: 'csv';
|
|
27
|
+
type: 'pointset';
|
|
28
|
+
};
|
|
29
|
+
export type JsonTable = CommonTable & {
|
|
30
|
+
source: 'json';
|
|
31
|
+
type: 'pointset';
|
|
32
|
+
};
|
|
33
|
+
export type AnyTable = CommonTable & {
|
|
34
|
+
source: 'user';
|
|
35
|
+
type: 'pointset';
|
|
36
|
+
};
|
|
37
|
+
export interface CommonTable {
|
|
38
|
+
name: string;
|
|
39
|
+
columns: Column[];
|
|
40
|
+
}
|
|
41
|
+
export interface Column {
|
|
42
|
+
name: string;
|
|
43
|
+
type: string;
|
|
44
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* OSM tag value definitions used across Overpass queries and layer classification.
|
|
3
|
+
*
|
|
4
|
+
* Centralized here so both the Overpass query builder and the SQL layer filters
|
|
5
|
+
* reference the same source of truth.
|
|
6
|
+
*/
|
|
7
|
+
export declare const PARKS_LEISURE_VALUES: readonly ["dog_park", "park", "playground", "recreation_ground"];
|
|
8
|
+
export declare const PARKS_LANDUSE_VALUES: readonly ["wood", "grass", "forest", "orchard", "village_green", "vineyard", "cemetery", "meadow"];
|
|
9
|
+
export declare const PARKS_NATURAL_VALUES: readonly ["wood", "grass", "grassland", "forest", "scrub", "heath", "meadow"];
|
|
10
|
+
export declare const WATER_NATURAL_VALUES: readonly ["water", "wetland", "strait", "spring"];
|
|
11
|
+
export declare const WATER_FEATURE_VALUES: readonly ["pond", "reservoir", "lagoon", "stream_pool", "lake", "pool", "canal", "river"];
|
|
12
|
+
export declare const EXCLUDED_HIGHWAY_VALUES: readonly ["cycleway", "elevator", "footway", "steps", "pedestrian", "proposed", "construction", "abandoned", "platform", "raceway"];
|
|
13
|
+
export declare const EXCLUDED_BUILDING_VALUES: readonly ["shed", "garage", "garages", "carport", "hut", "kiosk", "toilets", "service", "transformer_tower", "sty", "container"];
|
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
import { CsvTable, CustomLayerTable, LayerTable, JsonTable, Table, BoundingBox, GridLayerTable, GeoTiffTable } from '../shared/interfaces';
|
|
2
|
+
import { LoadLayerParams } from './use-cases/load-layer';
|
|
3
|
+
import { LoadCsvParams } from './use-cases/load-csv';
|
|
4
|
+
import { LoadJsonParams } from './use-cases/load-json';
|
|
5
|
+
import { FeatureCollection } from 'geojson';
|
|
6
|
+
import { LoadCustomLayerParams } from './use-cases/load-custom-layer';
|
|
7
|
+
import { SpatialQueryParams } from './use-cases/spatial-join/interfaces';
|
|
8
|
+
import { LoadOsmParams } from './use-cases/load-osm-from-overpass-api';
|
|
9
|
+
import { OsmLoadTimings } from './use-cases/load-osm-from-overpass-api/interfaces';
|
|
10
|
+
import { LoadGridLayerParams } from './use-cases/load-grid-layer/LoadGridLayerUseCase';
|
|
11
|
+
import { LoadGeoTiffParams } from './use-cases/load-geotiff';
|
|
12
|
+
import { RawQueryOutput, RawQueryParams } from './use-cases/raw-query/interfaces';
|
|
13
|
+
import { BuildHeatmapParams } from './use-cases/build-heatmap';
|
|
14
|
+
import { GetTableDataParams, GetTableDataOutput } from './use-cases/get-table-data';
|
|
15
|
+
import { UpdateTableParams } from './use-cases/update-table';
|
|
16
|
+
/**
|
|
17
|
+
* SpatialDb class provides methods to interact with a DuckDB database for spatial data operations.
|
|
18
|
+
*
|
|
19
|
+
* It allows loading OSM data, CSV, JSON, custom layers, and grid layers,
|
|
20
|
+
* as well as performing spatial joins and raw queries.
|
|
21
|
+
* DuckDB-backed spatial database for OSM, CSV, JSON, and raster data.
|
|
22
|
+
*
|
|
23
|
+
* Supports multiple isolated workspaces, each with its own schema and tables.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const db = new AutkSpatialDb();
|
|
27
|
+
* await db.init();
|
|
28
|
+
* const layer = await db.getLayer('osm_buildings');
|
|
29
|
+
*/
|
|
30
|
+
export declare class AutkSpatialDb {
|
|
31
|
+
private db?;
|
|
32
|
+
private conn?;
|
|
33
|
+
private currentWorkspace;
|
|
34
|
+
private workspaces;
|
|
35
|
+
get tables(): Array<Table>;
|
|
36
|
+
private osmProcessingPipeline?;
|
|
37
|
+
private loadOsmFromOverpassApiUseCase?;
|
|
38
|
+
private loadOsmFromPbfUseCase?;
|
|
39
|
+
private loadCsvUseCase?;
|
|
40
|
+
private loadLayerUseCase?;
|
|
41
|
+
private loadCustomLayerUseCase?;
|
|
42
|
+
private assignBuildingIdsUseCase?;
|
|
43
|
+
private loadJsonUseCase?;
|
|
44
|
+
private getLayerGeojsonUseCase?;
|
|
45
|
+
private spatialJoinUseCase?;
|
|
46
|
+
private getBoundingBoxFromLayerUseCase?;
|
|
47
|
+
private dropTableUseCase?;
|
|
48
|
+
private transformBoundingBoxCoordinatesUseCase?;
|
|
49
|
+
private loadGridLayerUseCase?;
|
|
50
|
+
private loadGeoTiffUseCase?;
|
|
51
|
+
private rawQueryUseCase?;
|
|
52
|
+
private getBoundingBoxFromOsmUseCase?;
|
|
53
|
+
private polygonizeSurfaceLayerUseCase?;
|
|
54
|
+
private buildHeatmapUseCase?;
|
|
55
|
+
private getTableDataUseCase?;
|
|
56
|
+
private updateTableUseCase?;
|
|
57
|
+
/**
|
|
58
|
+
* Gets the workspace data for the current workspace.
|
|
59
|
+
* @returns The WorkspaceData for the current workspace.
|
|
60
|
+
* @private
|
|
61
|
+
*/
|
|
62
|
+
private getCurrentWorkspaceData;
|
|
63
|
+
/**
|
|
64
|
+
* Initializes DuckDB, loads the spatial extension, and creates use-case instances.
|
|
65
|
+
*
|
|
66
|
+
* @returns A promise that resolves when initialization is complete.
|
|
67
|
+
* @throws If DuckDB WebAssembly fails to load or the spatial extension cannot be installed.
|
|
68
|
+
* @example
|
|
69
|
+
* await db.init();
|
|
70
|
+
*/
|
|
71
|
+
init(): Promise<void>;
|
|
72
|
+
/**
|
|
73
|
+
* Switches to a workspace, creating it if it doesn't exist.
|
|
74
|
+
*
|
|
75
|
+
* @param name The name of the workspace to switch to.
|
|
76
|
+
* @returns A promise that resolves when the workspace is set.
|
|
77
|
+
* @throws If the database has not been initialized.
|
|
78
|
+
*/
|
|
79
|
+
setWorkspace(name: string): Promise<void>;
|
|
80
|
+
/**
|
|
81
|
+
* Gets the list of all available workspaces.
|
|
82
|
+
* @returns An array of workspace names.
|
|
83
|
+
*/
|
|
84
|
+
getWorkspaces(): string[];
|
|
85
|
+
/**
|
|
86
|
+
* Gets the name of the current active workspace.
|
|
87
|
+
* @returns The current workspace name.
|
|
88
|
+
*/
|
|
89
|
+
getCurrentWorkspace(): string;
|
|
90
|
+
/**
|
|
91
|
+
* Registers a table in the current workspace's tables array. If a table with the same name already exists,
|
|
92
|
+
* it will be replaced and a warning will be logged to the console.
|
|
93
|
+
* @param table - The table to register.
|
|
94
|
+
*/
|
|
95
|
+
private _registerTable;
|
|
96
|
+
private clipLayerToSurface;
|
|
97
|
+
/**
|
|
98
|
+
* Loads OSM data from the Overpass API and optionally loads layers based on the provided parameters.
|
|
99
|
+
* When autoLoadLayers is enabled, this method will automatically extract and process specific layers
|
|
100
|
+
* (e.g., buildings, roads, surface) from the OSM data, and optionally polygonize the surface layer.
|
|
101
|
+
*
|
|
102
|
+
* @param params - Parameters for loading OSM data and layers.
|
|
103
|
+
* @returns A promise that resolves when the OSM data and layers are fully loaded.
|
|
104
|
+
* @throws Error if the database or connection is not initialized.
|
|
105
|
+
*/
|
|
106
|
+
loadOsm(params: LoadOsmParams): Promise<OsmLoadTimings>;
|
|
107
|
+
/**
|
|
108
|
+
* Loads a CSV file into the database and returns the created CsvTable.
|
|
109
|
+
* @param params - Parameters for loading the CSV file, including file path and table name.
|
|
110
|
+
* @returns A promise that resolves to the created CsvTable.
|
|
111
|
+
* @throws Error if the database or connection is not initialized.
|
|
112
|
+
*/
|
|
113
|
+
loadCsv(params: LoadCsvParams): Promise<CsvTable>;
|
|
114
|
+
/**
|
|
115
|
+
* Loads a JSON file into the database and returns the created JsonTable.
|
|
116
|
+
* @param params - Parameters for loading the JSON file, including file path and table name.
|
|
117
|
+
* @returns A promise that resolves to the created JsonTable.
|
|
118
|
+
* @throws Error if the database or connection is not initialized.
|
|
119
|
+
*/
|
|
120
|
+
loadJson(params: LoadJsonParams): Promise<JsonTable>;
|
|
121
|
+
/**
|
|
122
|
+
* Loads a layer from an OSM input table and returns the created LayerTable.
|
|
123
|
+
* @param params - Parameters for loading the layer.
|
|
124
|
+
* @returns A promise that resolves to the created LayerTable.
|
|
125
|
+
* @throws Error if the database or connection is not initialized.
|
|
126
|
+
* @throws Error if the OSM input table is not found or is not of the correct type.
|
|
127
|
+
*/
|
|
128
|
+
loadLayer(params: LoadLayerParams): Promise<LayerTable>;
|
|
129
|
+
/**
|
|
130
|
+
* Loads a custom layer from a GeoJSON file and returns the created CustomLayerTable.
|
|
131
|
+
* If OSM bounding box is available, it will be automatically applied to crop the layer.
|
|
132
|
+
* @param params - Parameters for loading the custom layer, including file path, table name, and layer type.
|
|
133
|
+
* @returns A promise that resolves to the created CustomLayerTable.
|
|
134
|
+
* @throws Error if the database or connection is not initialized.
|
|
135
|
+
*/
|
|
136
|
+
loadCustomLayer(params: LoadCustomLayerParams): Promise<CustomLayerTable>;
|
|
137
|
+
/**
|
|
138
|
+
* Loads a grid layer and returns the created GridLayerTable.
|
|
139
|
+
* If no bounding box is provided in params, the OSM bounding box will be used if available.
|
|
140
|
+
* @param params - Parameters for loading the grid layer, including grid size, cell size, and optional bounding box.
|
|
141
|
+
* @returns A promise that resolves to the created GridLayerTable.
|
|
142
|
+
* @throws Error if the database or connection is not initialized.
|
|
143
|
+
*/
|
|
144
|
+
loadGridLayer(params: LoadGridLayerParams): Promise<GridLayerTable>;
|
|
145
|
+
/**
|
|
146
|
+
* Loads a GeoTIFF raster file into the database.
|
|
147
|
+
* Uses DuckDB's spatial extension (GDAL-backed ST_Read) to parse the file.
|
|
148
|
+
* The resulting table has a `geometry` column (cell centroids) and a
|
|
149
|
+
* `properties` struct column containing one field per raster band.
|
|
150
|
+
* @param params - Parameters including the file URL or ArrayBuffer, output table name,
|
|
151
|
+
* and optional coordinate transformation settings.
|
|
152
|
+
* @returns A promise that resolves to the created GeoTiffTable.
|
|
153
|
+
*/
|
|
154
|
+
loadGeoTiff(params: LoadGeoTiffParams): Promise<GeoTiffTable>;
|
|
155
|
+
/**
|
|
156
|
+
* Retrieves a loaded GeoTIFF table as a FeatureCollection suitable for rendering with autk-map.
|
|
157
|
+
*
|
|
158
|
+
* The returned collection has a single feature whose `properties.raster` is an array of per-pixel
|
|
159
|
+
* property objects (one per cell, in row-major top-to-bottom order), plus `rasterResX` / `rasterResY`
|
|
160
|
+
* dimensions and a `bbox`.
|
|
161
|
+
*
|
|
162
|
+
* Pass the result directly to `AutkMap.loadRasterCollection()` and supply a `property` callback that
|
|
163
|
+
* extracts the numeric band value you want to visualise, e.g. `(cell) => cell.band_1 ?? 0`.
|
|
164
|
+
*
|
|
165
|
+
* @param tableName - The name of the GeoTiff table (as given to `loadGeoTiff`).
|
|
166
|
+
* @returns A promise that resolves to a packed raster FeatureCollection.
|
|
167
|
+
*/
|
|
168
|
+
getGeoTiffLayer(tableName: string): Promise<FeatureCollection<null>>;
|
|
169
|
+
/**
|
|
170
|
+
* Retrieves the GeoJSON representation of a layer by its table name.
|
|
171
|
+
* The returned FeatureCollection will include a bbox property with the layer's bounding box.
|
|
172
|
+
* @param layerTableName - The name of the layer table to retrieve.
|
|
173
|
+
* @returns A promise that resolves to the GeoJSON FeatureCollection of the layer with bbox.
|
|
174
|
+
* @throws Error if the database or connection is not initialized.
|
|
175
|
+
* @throws Error if the layer table is not found or is not a Layer table.
|
|
176
|
+
*/
|
|
177
|
+
getLayer(layerTableName: string): Promise<FeatureCollection>;
|
|
178
|
+
/**
|
|
179
|
+
* Retrieves the OSM bounding box for the current workspace.
|
|
180
|
+
*
|
|
181
|
+
* @returns The bounding box as `[minLon, minLat, maxLon, maxLat]`, or `null` if no OSM data has been loaded.
|
|
182
|
+
* @throws Never throws.
|
|
183
|
+
*/
|
|
184
|
+
getOsmBoundingBox(): [number, number, number, number] | null;
|
|
185
|
+
/**
|
|
186
|
+
* Returns the OSM bounding box in WGS84 (EPSG:4326) for clipping rasters.
|
|
187
|
+
*
|
|
188
|
+
* @returns The bounding box or `null` if no OSM data has been loaded.
|
|
189
|
+
* @throws Never throws.
|
|
190
|
+
*/
|
|
191
|
+
getOsmBoundingBoxWgs84(): BoundingBox | null;
|
|
192
|
+
/**
|
|
193
|
+
* Retrieves the bounding box of a layer by its table name.
|
|
194
|
+
* @param layerName - The name of the layer table to retrieve the bounding box from.
|
|
195
|
+
* @returns A promise that resolves to the bounding box of the layer.
|
|
196
|
+
* @throws Error if the database or connection is not initialized.
|
|
197
|
+
* @throws Error if the layer table is not found.
|
|
198
|
+
* @throws Error if the layer table does not have a geometry column.
|
|
199
|
+
*/
|
|
200
|
+
getBoundingBoxFromLayer(layerName: string): Promise<BoundingBox>;
|
|
201
|
+
/**
|
|
202
|
+
* Retrieves all layer tables from the loaded tables.
|
|
203
|
+
*
|
|
204
|
+
* @returns An array of `LayerTable` and `CustomLayerTable` objects.
|
|
205
|
+
* @throws Never throws.
|
|
206
|
+
*/
|
|
207
|
+
getLayerTables(): Array<LayerTable | CustomLayerTable>;
|
|
208
|
+
/**
|
|
209
|
+
* Retrieves the data from any table as an array of plain JavaScript objects.
|
|
210
|
+
* This method works with all table types (CSV, JSON, Layer, Grid, etc.).
|
|
211
|
+
* @param params - Parameters including table name and optional pagination (limit, offset).
|
|
212
|
+
* @returns A promise that resolves to an array of objects representing the table rows.
|
|
213
|
+
* @throws Error if the database or connection is not initialized.
|
|
214
|
+
* @throws Error if the table is not found.
|
|
215
|
+
*/
|
|
216
|
+
getTableData(params: GetTableDataParams): Promise<GetTableDataOutput>;
|
|
217
|
+
/**
|
|
218
|
+
* Updates an existing table with new data.
|
|
219
|
+
*
|
|
220
|
+
* For layer tables (OSM, GeoJSON), the input data should be a GeoJSON FeatureCollection.
|
|
221
|
+
* For non-layer tables (CSV, JSON), the input data should be an array of objects.
|
|
222
|
+
*
|
|
223
|
+
* @param params - Parameters for updating the table:
|
|
224
|
+
* - tableName: The name of the table to update
|
|
225
|
+
* - data: The new data (FeatureCollection for layers, Record<string, unknown>[] for CSV/JSON)
|
|
226
|
+
* - strategy: 'replace' (drop and recreate) or 'update' (update existing records by ID)
|
|
227
|
+
* - idColumn: Required for 'update' strategy. Supports 'id' or 'properties.attribute_name' format
|
|
228
|
+
* @returns A promise that resolves to the updated Table with refreshed column metadata.
|
|
229
|
+
* @throws Error if the database or connection is not initialized.
|
|
230
|
+
* @throws Error if the table is not found.
|
|
231
|
+
* @throws Error if idColumn is not provided when using 'update' strategy.
|
|
232
|
+
*/
|
|
233
|
+
updateTable(params: Omit<UpdateTableParams, 'workspace'>): Promise<Table>;
|
|
234
|
+
/**
|
|
235
|
+
* Performs a spatial join between two tables and returns the resulting table.
|
|
236
|
+
* The method can either create a new table or update an existing one based on the parameters.
|
|
237
|
+
* @param params - Parameters for the spatial join operation, including source and target tables, join type, and output table name.
|
|
238
|
+
* @returns A promise that resolves to the resulting table after the spatial join.
|
|
239
|
+
* @throws Error if the database or connection is not initialized.
|
|
240
|
+
*/
|
|
241
|
+
spatialQuery(params: SpatialQueryParams): Promise<Table>;
|
|
242
|
+
/**
|
|
243
|
+
* Executes a raw SQL query and returns the result.
|
|
244
|
+
* @param params - Parameters for the raw query, including the SQL query string and output type.
|
|
245
|
+
* @returns A promise that resolves to a Table if output type is 'CREATE_TABLE', otherwise returns the query result of type T.
|
|
246
|
+
* @throws Error if the database or connection is not initialized.
|
|
247
|
+
*/
|
|
248
|
+
rawQuery<T = RawQueryOutput>(params: RawQueryParams): Promise<T | Table>;
|
|
249
|
+
/**
|
|
250
|
+
* Drops a table from the database and removes it from the current workspace.
|
|
251
|
+
* @param tableName - The name of the table to remove.
|
|
252
|
+
* @returns A promise that resolves when the table has been dropped.
|
|
253
|
+
* @throws Error if the database or connection is not initialized.
|
|
254
|
+
*/
|
|
255
|
+
removeLayer(tableName: string): Promise<void>;
|
|
256
|
+
/**
|
|
257
|
+
* Builds a heatmap from spatial data by creating a grid and aggregating values.
|
|
258
|
+
* The heatmap is generated by creating a grid over the bounding box and aggregating values from the source table into each grid cell.
|
|
259
|
+
* @param params - Parameters for building the heatmap, including source table, grid configuration, and aggregation method.
|
|
260
|
+
* @returns A promise that resolves to the resulting GridLayerTable containing the heatmap data.
|
|
261
|
+
* @throws Error if the database or connection is not initialized.
|
|
262
|
+
*/
|
|
263
|
+
buildHeatmap(params: BuildHeatmapParams): Promise<Table>;
|
|
264
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
|
|
2
|
+
export interface DropTableParams {
|
|
3
|
+
tableName: string;
|
|
4
|
+
workspace?: string;
|
|
5
|
+
}
|
|
6
|
+
export interface DropTableResult {
|
|
7
|
+
success: boolean;
|
|
8
|
+
message: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Drops a table from the current workspace.
|
|
12
|
+
*/
|
|
13
|
+
export declare class DropTableUseCase {
|
|
14
|
+
private conn;
|
|
15
|
+
constructor(conn: AsyncDuckDBConnection);
|
|
16
|
+
/**
|
|
17
|
+
* Drops the specified table, returning success/failure rather than throwing.
|
|
18
|
+
*
|
|
19
|
+
* @param params.tableName Name of the table to drop.
|
|
20
|
+
* @param params.workspace Optional workspace name (defaults to `main`).
|
|
21
|
+
* @returns Result indicating success or failure with a message.
|
|
22
|
+
* @throws Never throws. Errors are caught and returned in the result.
|
|
23
|
+
*/
|
|
24
|
+
exec(params: DropTableParams): Promise<DropTableResult>;
|
|
25
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { BoundingBox } from '../../../../shared/interfaces';
|
|
2
|
+
import { GetBoundingBoxFromAreaParams } from './interfaces';
|
|
3
|
+
/**
|
|
4
|
+
* Fetches bounding boxes for named areas from the Overpass API.
|
|
5
|
+
*/
|
|
6
|
+
export declare class GetBoundingBoxFromAreaUseCase {
|
|
7
|
+
/**
|
|
8
|
+
* Fetches and merges bounding boxes for multiple named areas.
|
|
9
|
+
*
|
|
10
|
+
* @param params.queryArea Geocode scope and area names.
|
|
11
|
+
* @returns Combined bounding box spanning all areas.
|
|
12
|
+
* @throws If no bounding box can be determined.
|
|
13
|
+
*/
|
|
14
|
+
exec(params: GetBoundingBoxFromAreaParams): Promise<BoundingBox>;
|
|
15
|
+
private fetchBoundingBoxForArea;
|
|
16
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
|
|
2
|
+
import { GetBoundingBoxFromLayerParams } from './interfaces';
|
|
3
|
+
import { BoundingBox } from '../../../../shared/interfaces';
|
|
4
|
+
/**
|
|
5
|
+
* Computes the geographic bounding box of a layer table.
|
|
6
|
+
*/
|
|
7
|
+
export declare class GetBoundingBoxFromLayerUseCase {
|
|
8
|
+
private conn;
|
|
9
|
+
constructor(conn: AsyncDuckDBConnection);
|
|
10
|
+
/**
|
|
11
|
+
* Queries the spatial extent of a layer's geometry column.
|
|
12
|
+
*
|
|
13
|
+
* @param params.layerTableName Name of the layer table.
|
|
14
|
+
* @param params.workspace Optional workspace name (defaults to `main`).
|
|
15
|
+
* @returns Named bounding box with `minLon`, `minLat`, `maxLon`, `maxLat`.
|
|
16
|
+
* @throws If the table has no geometries or invalid coordinates.
|
|
17
|
+
*/
|
|
18
|
+
exec(params: GetBoundingBoxFromLayerParams): Promise<BoundingBox>;
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const GET_BOUNDING_BOX_FROM_LAYER_QUERY: (layerTableName: string, workspace: string) => string;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
|
|
2
|
+
import { BoundingBox } from '../../../../shared/interfaces';
|
|
3
|
+
import { GetBoundingBoxFromOsmParams } from './interfaces';
|
|
4
|
+
/**
|
|
5
|
+
* Computes the geographic bounding box of an OSM boundary table.
|
|
6
|
+
*/
|
|
7
|
+
export declare class GetBoundingBoxFromOsmUseCase {
|
|
8
|
+
private conn;
|
|
9
|
+
constructor(conn: AsyncDuckDBConnection);
|
|
10
|
+
/**
|
|
11
|
+
* Queries the spatial extent of boundary way geometries in an OSM table.
|
|
12
|
+
*
|
|
13
|
+
* @param params.osmTableName Name of the OSM boundaries table.
|
|
14
|
+
* @param params.workspace Optional workspace name (defaults to `main`).
|
|
15
|
+
* @returns Named bounding box.
|
|
16
|
+
* @throws If the table has no coordinates or invalid values.
|
|
17
|
+
*/
|
|
18
|
+
exec(params: GetBoundingBoxFromOsmParams): Promise<BoundingBox>;
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const GET_BOUNDING_BOX_FROM_OSM_QUERY: (osmTableName: string, workspace: string) => string;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
|
|
2
|
+
import { TransformBoundingBoxCoordinatesParams } from './interfaces';
|
|
3
|
+
import { BoundingBox } from '../../../../shared/interfaces';
|
|
4
|
+
/**
|
|
5
|
+
* Transforms a bounding box between coordinate reference systems.
|
|
6
|
+
*/
|
|
7
|
+
export declare class TransformBoundingBoxCoordinatesUseCase {
|
|
8
|
+
private conn;
|
|
9
|
+
constructor(conn: AsyncDuckDBConnection);
|
|
10
|
+
/**
|
|
11
|
+
* Transforms bounding box coordinates using DuckDB's `ST_Transform`.
|
|
12
|
+
* EPSG:4326 inputs are returned unchanged.
|
|
13
|
+
*
|
|
14
|
+
* @param params.boundingBox Source bounding box to transform.
|
|
15
|
+
* @param params.coordinateFormat Target CRS (e.g. `EPSG:3857`).
|
|
16
|
+
* @returns Transformed bounding box.
|
|
17
|
+
* @throws If the coordinate transformation fails.
|
|
18
|
+
*/
|
|
19
|
+
exec(params: TransformBoundingBoxCoordinatesParams): Promise<BoundingBox>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type Params = {
|
|
2
|
+
boundingBox: {
|
|
3
|
+
minLat: number;
|
|
4
|
+
maxLat: number;
|
|
5
|
+
minLon: number;
|
|
6
|
+
maxLon: number;
|
|
7
|
+
};
|
|
8
|
+
coordinateFormat: string;
|
|
9
|
+
};
|
|
10
|
+
export declare const TRANSFORM_BOUNDING_BOX_COORDINATES_QUERY: ({ boundingBox, coordinateFormat }: Params) => string;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Column } from '../../shared/interfaces';
|
|
2
|
+
type DuckDbTableDescriptionColumn = {
|
|
3
|
+
column_name: string;
|
|
4
|
+
column_type: string;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* Converts DuckDB `DESCRIBE` output rows into `Column` metadata objects.
|
|
8
|
+
*
|
|
9
|
+
* @param tableDescribeResponse Array of `{ column_name, column_type }` rows from DuckDB.
|
|
10
|
+
* @returns Array of `{ name, type }` column descriptors.
|
|
11
|
+
* @throws Never throws.
|
|
12
|
+
*/
|
|
13
|
+
export declare function getColumnsFromDuckDbTableDescribe(tableDescribeResponse: Array<DuckDbTableDescriptionColumn>): Array<Column>;
|
|
14
|
+
/**
|
|
15
|
+
* Recursively converts values returned by DuckDB-Wasm / Apache Arrow into
|
|
16
|
+
* plain JavaScript values so they can be safely logged or serialised. It
|
|
17
|
+
* handles nested arrays, structs and any object exposing a `toJSON()` method.
|
|
18
|
+
*/
|
|
19
|
+
export declare function toPlain<T = unknown>(value: T): T;
|
|
20
|
+
export {};
|
package/dist/src/spatial/use-cases/aggregate-building-layer/AggregateBuildingLayerUseCase.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
|
|
2
|
+
/**
|
|
3
|
+
* Aggregates building geometries by `building_id` into union geometries.
|
|
4
|
+
*/
|
|
5
|
+
export declare class AggregateBuildingLayerUseCase {
|
|
6
|
+
private conn;
|
|
7
|
+
constructor(conn: AsyncDuckDBConnection);
|
|
8
|
+
exec(params: {
|
|
9
|
+
inputTableName: string;
|
|
10
|
+
workspace?: string;
|
|
11
|
+
}): Promise<void>;
|
|
12
|
+
}
|