@honua/app-platform 0.0.20-alpha.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/LICENSE +201 -0
- package/README.md +11 -0
- package/app/index.d.ts +164 -0
- package/app/index.d.ts.map +1 -0
- package/app/index.js +424 -0
- package/app-controller/controller.d.ts +425 -0
- package/app-controller/controller.d.ts.map +1 -0
- package/app-controller/controller.js +1173 -0
- package/app-controller/index.d.ts +14 -0
- package/app-controller/index.d.ts.map +1 -0
- package/app-controller/index.js +12 -0
- package/app-workspace/index.d.ts +421 -0
- package/app-workspace/index.d.ts.map +1 -0
- package/app-workspace/index.js +722 -0
- package/collaboration/client.d.ts +40 -0
- package/collaboration/client.d.ts.map +1 -0
- package/collaboration/client.js +299 -0
- package/collaboration/errors.d.ts +15 -0
- package/collaboration/errors.d.ts.map +1 -0
- package/collaboration/errors.js +17 -0
- package/collaboration/fixture.d.ts +41 -0
- package/collaboration/fixture.d.ts.map +1 -0
- package/collaboration/fixture.js +362 -0
- package/collaboration/index.d.ts +18 -0
- package/collaboration/index.d.ts.map +1 -0
- package/collaboration/index.js +14 -0
- package/collaboration/types.d.ts +240 -0
- package/collaboration/types.d.ts.map +1 -0
- package/collaboration/types.js +1 -0
- package/contract/analytics-sources.d.ts +149 -0
- package/contract/analytics-sources.d.ts.map +1 -0
- package/contract/analytics-sources.js +235 -0
- package/contract/edit-session.d.ts +203 -0
- package/contract/edit-session.d.ts.map +1 -0
- package/contract/edit-session.js +760 -0
- package/contract/edit-sketch.d.ts +91 -0
- package/contract/edit-sketch.d.ts.map +1 -0
- package/contract/edit-sketch.js +281 -0
- package/contract/index.d.ts +63 -0
- package/contract/index.d.ts.map +1 -0
- package/contract/index.js +52 -0
- package/contract/jobs.d.ts +149 -0
- package/contract/jobs.d.ts.map +1 -0
- package/contract/jobs.js +40 -0
- package/contract/pmtiles.d.ts +162 -0
- package/contract/pmtiles.d.ts.map +1 -0
- package/contract/pmtiles.js +155 -0
- package/contract/source.d.ts +447 -0
- package/contract/source.d.ts.map +1 -0
- package/contract/source.js +3909 -0
- package/contract/spatial-aggregation.d.ts +336 -0
- package/contract/spatial-aggregation.d.ts.map +1 -0
- package/contract/spatial-aggregation.js +298 -0
- package/contract/temporal.d.ts +455 -0
- package/contract/temporal.d.ts.map +1 -0
- package/contract/temporal.js +146 -0
- package/contract/tiles.d.ts +370 -0
- package/contract/tiles.d.ts.map +1 -0
- package/contract/tiles.js +519 -0
- package/contract/types.d.ts +694 -0
- package/contract/types.d.ts.map +1 -0
- package/contract/types.js +183 -0
- package/contract/widget-source.d.ts +205 -0
- package/contract/widget-source.d.ts.map +1 -0
- package/contract/widget-source.js +1473 -0
- package/control-plane/client.d.ts +95 -0
- package/control-plane/client.d.ts.map +1 -0
- package/control-plane/client.js +374 -0
- package/control-plane/index.d.ts +18 -0
- package/control-plane/index.d.ts.map +1 -0
- package/control-plane/index.js +14 -0
- package/control-plane/types.d.ts +233 -0
- package/control-plane/types.d.ts.map +1 -0
- package/control-plane/types.js +7 -0
- package/controls/basemap-style-binding.d.ts +54 -0
- package/controls/basemap-style-binding.d.ts.map +1 -0
- package/controls/basemap-style-binding.js +199 -0
- package/controls/basemap-switcher.d.ts +95 -0
- package/controls/basemap-switcher.d.ts.map +1 -0
- package/controls/basemap-switcher.js +379 -0
- package/controls/element-utils.d.ts +48 -0
- package/controls/element-utils.d.ts.map +1 -0
- package/controls/element-utils.js +78 -0
- package/controls/index.d.ts +33 -0
- package/controls/index.d.ts.map +1 -0
- package/controls/index.js +30 -0
- package/controls/layer-list.d.ts +98 -0
- package/controls/layer-list.d.ts.map +1 -0
- package/controls/layer-list.js +375 -0
- package/controls/legend-derive.d.ts +53 -0
- package/controls/legend-derive.d.ts.map +1 -0
- package/controls/legend-derive.js +196 -0
- package/controls/legend.d.ts +104 -0
- package/controls/legend.d.ts.map +1 -0
- package/controls/legend.js +381 -0
- package/controls/swipe-control.d.ts +80 -0
- package/controls/swipe-control.d.ts.map +1 -0
- package/controls/swipe-control.js +368 -0
- package/controls/types.d.ts +227 -0
- package/controls/types.d.ts.map +1 -0
- package/controls/types.js +11 -0
- package/core/auth/client-credentials-provider.d.ts +51 -0
- package/core/auth/client-credentials-provider.d.ts.map +1 -0
- package/core/auth/client-credentials-provider.js +115 -0
- package/core/auth/credential-store.d.ts +52 -0
- package/core/auth/credential-store.d.ts.map +1 -0
- package/core/auth/credential-store.js +82 -0
- package/core/auth/index.d.ts +23 -0
- package/core/auth/index.d.ts.map +1 -0
- package/core/auth/index.js +20 -0
- package/core/auth/oauth2-provider.d.ts +114 -0
- package/core/auth/oauth2-provider.d.ts.map +1 -0
- package/core/auth/oauth2-provider.js +408 -0
- package/core/auth/pkce.d.ts +25 -0
- package/core/auth/pkce.d.ts.map +1 -0
- package/core/auth/pkce.js +46 -0
- package/core/auth/static-providers.d.ts +20 -0
- package/core/auth/static-providers.d.ts.map +1 -0
- package/core/auth/static-providers.js +26 -0
- package/core/auth/token-endpoint.d.ts +40 -0
- package/core/auth/token-endpoint.d.ts.map +1 -0
- package/core/auth/token-endpoint.js +133 -0
- package/core/auth/types.d.ts +144 -0
- package/core/auth/types.d.ts.map +1 -0
- package/core/auth/types.js +8 -0
- package/core/batch.d.ts +37 -0
- package/core/batch.d.ts.map +1 -0
- package/core/batch.js +79 -0
- package/core/cache-state.d.ts +79 -0
- package/core/cache-state.d.ts.map +1 -0
- package/core/cache-state.js +87 -0
- package/core/client.d.ts +607 -0
- package/core/client.d.ts.map +1 -0
- package/core/client.js +1716 -0
- package/core/compatibility.d.ts +18 -0
- package/core/compatibility.d.ts.map +1 -0
- package/core/compatibility.js +245 -0
- package/core/errors.d.ts +139 -0
- package/core/errors.d.ts.map +1 -0
- package/core/errors.js +176 -0
- package/core/esri-geojson.d.ts +66 -0
- package/core/esri-geojson.d.ts.map +1 -0
- package/core/esri-geojson.js +363 -0
- package/core/geoparquet-sql.d.ts +162 -0
- package/core/geoparquet-sql.d.ts.map +1 -0
- package/core/geoparquet-sql.js +333 -0
- package/core/geoservices.d.ts +34 -0
- package/core/geoservices.d.ts.map +1 -0
- package/core/geoservices.js +434 -0
- package/core/grpc-adapter.d.ts +23 -0
- package/core/grpc-adapter.d.ts.map +1 -0
- package/core/grpc-adapter.js +688 -0
- package/core/odata.d.ts +347 -0
- package/core/odata.d.ts.map +1 -0
- package/core/odata.js +913 -0
- package/core/ogc-conformance.d.ts +35 -0
- package/core/ogc-conformance.d.ts.map +1 -0
- package/core/ogc-conformance.js +134 -0
- package/core/ogc-endpoint-layout.d.ts +70 -0
- package/core/ogc-endpoint-layout.d.ts.map +1 -0
- package/core/ogc-endpoint-layout.js +173 -0
- package/core/ogc-features.d.ts +23 -0
- package/core/ogc-features.d.ts.map +1 -0
- package/core/ogc-features.js +129 -0
- package/core/ogc-maps.d.ts +49 -0
- package/core/ogc-maps.d.ts.map +1 -0
- package/core/ogc-maps.js +126 -0
- package/core/ogc-processes.d.ts +118 -0
- package/core/ogc-processes.d.ts.map +1 -0
- package/core/ogc-processes.js +423 -0
- package/core/ogc-records.d.ts +75 -0
- package/core/ogc-records.d.ts.map +1 -0
- package/core/ogc-records.js +251 -0
- package/core/ogc-tiles.d.ts +125 -0
- package/core/ogc-tiles.d.ts.map +1 -0
- package/core/ogc-tiles.js +183 -0
- package/core/path-utils.d.ts +69 -0
- package/core/path-utils.d.ts.map +1 -0
- package/core/path-utils.js +123 -0
- package/core/pbf-decoder.d.ts +39 -0
- package/core/pbf-decoder.d.ts.map +1 -0
- package/core/pbf-decoder.js +702 -0
- package/core/process-runner.d.ts +104 -0
- package/core/process-runner.d.ts.map +1 -0
- package/core/process-runner.js +315 -0
- package/core/protocol-transport.d.ts +76 -0
- package/core/protocol-transport.d.ts.map +1 -0
- package/core/protocol-transport.js +15 -0
- package/core/query-builder.d.ts +261 -0
- package/core/query-builder.d.ts.map +1 -0
- package/core/query-builder.js +538 -0
- package/core/request-pipeline.d.ts +88 -0
- package/core/request-pipeline.d.ts.map +1 -0
- package/core/request-pipeline.js +273 -0
- package/core/spatial-filter.d.ts +93 -0
- package/core/spatial-filter.d.ts.map +1 -0
- package/core/spatial-filter.js +153 -0
- package/core/stac-static.d.ts +51 -0
- package/core/stac-static.d.ts.map +1 -0
- package/core/stac-static.js +195 -0
- package/core/stac.d.ts +67 -0
- package/core/stac.d.ts.map +1 -0
- package/core/stac.js +259 -0
- package/core/surfaces.d.ts +540 -0
- package/core/surfaces.d.ts.map +1 -0
- package/core/surfaces.js +1964 -0
- package/core/terrain-elevation.d.ts +114 -0
- package/core/terrain-elevation.d.ts.map +1 -0
- package/core/terrain-elevation.js +150 -0
- package/core/types.d.ts +1404 -0
- package/core/types.d.ts.map +1 -0
- package/core/types.js +13 -0
- package/core/wfs-capabilities.d.ts +153 -0
- package/core/wfs-capabilities.d.ts.map +1 -0
- package/core/wfs-capabilities.js +490 -0
- package/core/wfs-filter.d.ts +118 -0
- package/core/wfs-filter.d.ts.map +1 -0
- package/core/wfs-filter.js +634 -0
- package/core/wfs.d.ts +232 -0
- package/core/wfs.d.ts.map +1 -0
- package/core/wfs.js +426 -0
- package/core/wire-shared.d.ts +32 -0
- package/core/wire-shared.d.ts.map +1 -0
- package/core/wire-shared.js +76 -0
- package/core/wms-axis.d.ts +36 -0
- package/core/wms-axis.d.ts.map +1 -0
- package/core/wms-axis.js +73 -0
- package/core/wms-capabilities.d.ts +110 -0
- package/core/wms-capabilities.d.ts.map +1 -0
- package/core/wms-capabilities.js +559 -0
- package/core/wms-types.d.ts +128 -0
- package/core/wms-types.d.ts.map +1 -0
- package/core/wms-types.js +32 -0
- package/core/wms.d.ts +144 -0
- package/core/wms.d.ts.map +1 -0
- package/core/wms.js +338 -0
- package/core/wmts-capabilities.d.ts +82 -0
- package/core/wmts-capabilities.d.ts.map +1 -0
- package/core/wmts-capabilities.js +402 -0
- package/core/wmts.d.ts +103 -0
- package/core/wmts.d.ts.map +1 -0
- package/core/wmts.js +332 -0
- package/core/xml-text.d.ts +20 -0
- package/core/xml-text.d.ts.map +1 -0
- package/core/xml-text.js +85 -0
- package/esri-compat/basemap-gallery.d.ts +38 -0
- package/esri-compat/basemap-gallery.d.ts.map +1 -0
- package/esri-compat/basemap-gallery.js +159 -0
- package/esri-compat/basemap-layer-list.d.ts +35 -0
- package/esri-compat/basemap-layer-list.d.ts.map +1 -0
- package/esri-compat/basemap-layer-list.js +139 -0
- package/esri-compat/basemap.d.ts +32 -0
- package/esri-compat/basemap.d.ts.map +1 -0
- package/esri-compat/basemap.js +84 -0
- package/esri-compat/bookmarks.d.ts +36 -0
- package/esri-compat/bookmarks.d.ts.map +1 -0
- package/esri-compat/bookmarks.js +108 -0
- package/esri-compat/class-breaks-renderer.d.ts +50 -0
- package/esri-compat/class-breaks-renderer.d.ts.map +1 -0
- package/esri-compat/class-breaks-renderer.js +164 -0
- package/esri-compat/color.d.ts +22 -0
- package/esri-compat/color.d.ts.map +1 -0
- package/esri-compat/color.js +106 -0
- package/esri-compat/controls.d.ts +174 -0
- package/esri-compat/controls.d.ts.map +1 -0
- package/esri-compat/controls.js +479 -0
- package/esri-compat/coordinate-conversion.d.ts +41 -0
- package/esri-compat/coordinate-conversion.d.ts.map +1 -0
- package/esri-compat/coordinate-conversion.js +125 -0
- package/esri-compat/directions.d.ts +45 -0
- package/esri-compat/directions.d.ts.map +1 -0
- package/esri-compat/directions.js +123 -0
- package/esri-compat/editor.d.ts +47 -0
- package/esri-compat/editor.d.ts.map +1 -0
- package/esri-compat/editor.js +170 -0
- package/esri-compat/esri-config.d.ts +16 -0
- package/esri-compat/esri-config.d.ts.map +1 -0
- package/esri-compat/esri-config.js +23 -0
- package/esri-compat/esri-request.d.ts +17 -0
- package/esri-compat/esri-request.d.ts.map +1 -0
- package/esri-compat/esri-request.js +127 -0
- package/esri-compat/event-bus.d.ts +106 -0
- package/esri-compat/event-bus.d.ts.map +1 -0
- package/esri-compat/event-bus.js +90 -0
- package/esri-compat/expand.d.ts +36 -0
- package/esri-compat/expand.d.ts.map +1 -0
- package/esri-compat/expand.js +97 -0
- package/esri-compat/extent.d.ts +43 -0
- package/esri-compat/extent.d.ts.map +1 -0
- package/esri-compat/extent.js +140 -0
- package/esri-compat/feature-filter.d.ts +55 -0
- package/esri-compat/feature-filter.d.ts.map +1 -0
- package/esri-compat/feature-filter.js +109 -0
- package/esri-compat/feature-form.d.ts +64 -0
- package/esri-compat/feature-form.d.ts.map +1 -0
- package/esri-compat/feature-form.js +137 -0
- package/esri-compat/feature-layer.d.ts +173 -0
- package/esri-compat/feature-layer.d.ts.map +1 -0
- package/esri-compat/feature-layer.js +661 -0
- package/esri-compat/feature-set.d.ts +32 -0
- package/esri-compat/feature-set.d.ts.map +1 -0
- package/esri-compat/feature-set.js +80 -0
- package/esri-compat/feature-table.d.ts +141 -0
- package/esri-compat/feature-table.d.ts.map +1 -0
- package/esri-compat/feature-table.js +500 -0
- package/esri-compat/feature-templates.d.ts +41 -0
- package/esri-compat/feature-templates.d.ts.map +1 -0
- package/esri-compat/feature-templates.js +97 -0
- package/esri-compat/feature.d.ts +33 -0
- package/esri-compat/feature.d.ts.map +1 -0
- package/esri-compat/feature.js +83 -0
- package/esri-compat/geojson-layer.d.ts +86 -0
- package/esri-compat/geojson-layer.d.ts.map +1 -0
- package/esri-compat/geojson-layer.js +191 -0
- package/esri-compat/geometry-engine.d.ts +107 -0
- package/esri-compat/geometry-engine.d.ts.map +1 -0
- package/esri-compat/geometry-engine.js +266 -0
- package/esri-compat/graphic.d.ts +46 -0
- package/esri-compat/graphic.d.ts.map +1 -0
- package/esri-compat/graphic.js +103 -0
- package/esri-compat/graphics-layer.d.ts +49 -0
- package/esri-compat/graphics-layer.d.ts.map +1 -0
- package/esri-compat/graphics-layer.js +185 -0
- package/esri-compat/group-layer.d.ts +48 -0
- package/esri-compat/group-layer.d.ts.map +1 -0
- package/esri-compat/group-layer.js +212 -0
- package/esri-compat/identify.d.ts +71 -0
- package/esri-compat/identify.d.ts.map +1 -0
- package/esri-compat/identify.js +299 -0
- package/esri-compat/identity-manager.d.ts +74 -0
- package/esri-compat/identity-manager.d.ts.map +1 -0
- package/esri-compat/identity-manager.js +245 -0
- package/esri-compat/imagery-layer.d.ts +78 -0
- package/esri-compat/imagery-layer.d.ts.map +1 -0
- package/esri-compat/imagery-layer.js +167 -0
- package/esri-compat/label-class.d.ts +31 -0
- package/esri-compat/label-class.d.ts.map +1 -0
- package/esri-compat/label-class.js +102 -0
- package/esri-compat/layer-list.d.ts +77 -0
- package/esri-compat/layer-list.d.ts.map +1 -0
- package/esri-compat/layer-list.js +342 -0
- package/esri-compat/legend.d.ts +53 -0
- package/esri-compat/legend.d.ts.map +1 -0
- package/esri-compat/legend.js +254 -0
- package/esri-compat/map-image-layer.d.ts +162 -0
- package/esri-compat/map-image-layer.d.ts.map +1 -0
- package/esri-compat/map-image-layer.js +709 -0
- package/esri-compat/map-view.d.ts +323 -0
- package/esri-compat/map-view.d.ts.map +1 -0
- package/esri-compat/map-view.js +1175 -0
- package/esri-compat/map.d.ts +47 -0
- package/esri-compat/map.d.ts.map +1 -0
- package/esri-compat/map.js +209 -0
- package/esri-compat/measurement-2d.d.ts +61 -0
- package/esri-compat/measurement-2d.d.ts.map +1 -0
- package/esri-compat/measurement-2d.js +184 -0
- package/esri-compat/measurement.d.ts +45 -0
- package/esri-compat/measurement.d.ts.map +1 -0
- package/esri-compat/measurement.js +193 -0
- package/esri-compat/oauth-info.d.ts +50 -0
- package/esri-compat/oauth-info.d.ts.map +1 -0
- package/esri-compat/oauth-info.js +142 -0
- package/esri-compat/picture-marker-symbol.d.ts +35 -0
- package/esri-compat/picture-marker-symbol.d.ts.map +1 -0
- package/esri-compat/picture-marker-symbol.js +126 -0
- package/esri-compat/point.d.ts +31 -0
- package/esri-compat/point.d.ts.map +1 -0
- package/esri-compat/point.js +102 -0
- package/esri-compat/polygon.d.ts +31 -0
- package/esri-compat/polygon.d.ts.map +1 -0
- package/esri-compat/polygon.js +107 -0
- package/esri-compat/polyline.d.ts +31 -0
- package/esri-compat/polyline.d.ts.map +1 -0
- package/esri-compat/polyline.js +107 -0
- package/esri-compat/popup-template.d.ts +55 -0
- package/esri-compat/popup-template.d.ts.map +1 -0
- package/esri-compat/popup-template.js +128 -0
- package/esri-compat/popup.d.ts +54 -0
- package/esri-compat/popup.d.ts.map +1 -0
- package/esri-compat/popup.js +312 -0
- package/esri-compat/print.d.ts +47 -0
- package/esri-compat/print.d.ts.map +1 -0
- package/esri-compat/print.js +105 -0
- package/esri-compat/query.d.ts +58 -0
- package/esri-compat/query.d.ts.map +1 -0
- package/esri-compat/query.js +128 -0
- package/esri-compat/reactive-utils.d.ts +24 -0
- package/esri-compat/reactive-utils.d.ts.map +1 -0
- package/esri-compat/reactive-utils.js +193 -0
- package/esri-compat/request.d.ts +41 -0
- package/esri-compat/request.d.ts.map +1 -0
- package/esri-compat/request.js +253 -0
- package/esri-compat/route-layer.d.ts +59 -0
- package/esri-compat/route-layer.d.ts.map +1 -0
- package/esri-compat/route-layer.js +223 -0
- package/esri-compat/route-task.d.ts +88 -0
- package/esri-compat/route-task.d.ts.map +1 -0
- package/esri-compat/route-task.js +225 -0
- package/esri-compat/scene-view.d.ts +41 -0
- package/esri-compat/scene-view.d.ts.map +1 -0
- package/esri-compat/scene-view.js +68 -0
- package/esri-compat/search.d.ts +112 -0
- package/esri-compat/search.d.ts.map +1 -0
- package/esri-compat/search.js +820 -0
- package/esri-compat/simple-fill-symbol.d.ts +27 -0
- package/esri-compat/simple-fill-symbol.d.ts.map +1 -0
- package/esri-compat/simple-fill-symbol.js +85 -0
- package/esri-compat/simple-line-symbol.d.ts +27 -0
- package/esri-compat/simple-line-symbol.d.ts.map +1 -0
- package/esri-compat/simple-line-symbol.js +85 -0
- package/esri-compat/simple-marker-symbol.d.ts +29 -0
- package/esri-compat/simple-marker-symbol.d.ts.map +1 -0
- package/esri-compat/simple-marker-symbol.js +92 -0
- package/esri-compat/simple-renderer.d.ts +29 -0
- package/esri-compat/simple-renderer.d.ts.map +1 -0
- package/esri-compat/simple-renderer.js +92 -0
- package/esri-compat/sketch.d.ts +64 -0
- package/esri-compat/sketch.d.ts.map +1 -0
- package/esri-compat/sketch.js +227 -0
- package/esri-compat/spatial-reference.d.ts +31 -0
- package/esri-compat/spatial-reference.d.ts.map +1 -0
- package/esri-compat/spatial-reference.js +102 -0
- package/esri-compat/swipe.d.ts +34 -0
- package/esri-compat/swipe.d.ts.map +1 -0
- package/esri-compat/swipe.js +93 -0
- package/esri-compat/table-list.d.ts +36 -0
- package/esri-compat/table-list.d.ts.map +1 -0
- package/esri-compat/table-list.js +126 -0
- package/esri-compat/text-symbol.d.ts +37 -0
- package/esri-compat/text-symbol.d.ts.map +1 -0
- package/esri-compat/text-symbol.js +123 -0
- package/esri-compat/tile-layer.d.ts +52 -0
- package/esri-compat/tile-layer.d.ts.map +1 -0
- package/esri-compat/tile-layer.js +168 -0
- package/esri-compat/time-slider.d.ts +70 -0
- package/esri-compat/time-slider.d.ts.map +1 -0
- package/esri-compat/time-slider.js +208 -0
- package/esri-compat/track.d.ts +51 -0
- package/esri-compat/track.d.ts.map +1 -0
- package/esri-compat/track.js +174 -0
- package/esri-compat/unique-value-renderer.d.ts +41 -0
- package/esri-compat/unique-value-renderer.d.ts.map +1 -0
- package/esri-compat/unique-value-renderer.js +127 -0
- package/esri-compat/url.d.ts +13 -0
- package/esri-compat/url.d.ts.map +1 -0
- package/esri-compat/url.js +68 -0
- package/esri-compat/vector-tile-layer.d.ts +47 -0
- package/esri-compat/vector-tile-layer.d.ts.map +1 -0
- package/esri-compat/vector-tile-layer.js +130 -0
- package/esri-compat/web-map.d.ts +14 -0
- package/esri-compat/web-map.d.ts.map +1 -0
- package/esri-compat/web-map.js +24 -0
- package/esri-compat/wfs-layer.d.ts +64 -0
- package/esri-compat/wfs-layer.d.ts.map +1 -0
- package/esri-compat/wfs-layer.js +145 -0
- package/esri-compat/wms-layer.d.ts +76 -0
- package/esri-compat/wms-layer.d.ts.map +1 -0
- package/esri-compat/wms-layer.js +157 -0
- package/exploration/context.d.ts +25 -0
- package/exploration/context.d.ts.map +1 -0
- package/exploration/context.js +396 -0
- package/exploration/index.d.ts +27 -0
- package/exploration/index.d.ts.map +1 -0
- package/exploration/index.js +24 -0
- package/exploration/presets.d.ts +27 -0
- package/exploration/presets.d.ts.map +1 -0
- package/exploration/presets.js +114 -0
- package/exploration/reducer.d.ts +23 -0
- package/exploration/reducer.d.ts.map +1 -0
- package/exploration/reducer.js +332 -0
- package/exploration/selection.d.ts +25 -0
- package/exploration/selection.d.ts.map +1 -0
- package/exploration/selection.js +34 -0
- package/exploration/selectors.d.ts +56 -0
- package/exploration/selectors.d.ts.map +1 -0
- package/exploration/selectors.js +110 -0
- package/exploration/types.d.ts +294 -0
- package/exploration/types.d.ts.map +1 -0
- package/exploration/types.js +33 -0
- package/expr/expression.d.ts +457 -0
- package/expr/expression.d.ts.map +1 -0
- package/expr/expression.js +663 -0
- package/expr/index.d.ts +32 -0
- package/expr/index.d.ts.map +1 -0
- package/expr/index.js +30 -0
- package/filter-registry/index.d.ts +145 -0
- package/filter-registry/index.d.ts.map +1 -0
- package/filter-registry/index.js +531 -0
- package/gen/honua/v1/feature_service_pb.d.ts +918 -0
- package/gen/honua/v1/feature_service_pb.d.ts.map +1 -0
- package/gen/honua/v1/feature_service_pb.js +375 -0
- package/generated-app/errors.d.ts +41 -0
- package/generated-app/errors.d.ts.map +1 -0
- package/generated-app/errors.js +41 -0
- package/generated-app/index.d.ts +17 -0
- package/generated-app/index.d.ts.map +1 -0
- package/generated-app/index.js +12 -0
- package/generated-app/manifest.d.ts +183 -0
- package/generated-app/manifest.d.ts.map +1 -0
- package/generated-app/manifest.js +14 -0
- package/generated-app/projection.d.ts +44 -0
- package/generated-app/projection.d.ts.map +1 -0
- package/generated-app/projection.js +234 -0
- package/generated-app/runtime.d.ts +215 -0
- package/generated-app/runtime.d.ts.map +1 -0
- package/generated-app/runtime.js +1196 -0
- package/geocoding/index.d.ts +106 -0
- package/geocoding/index.d.ts.map +1 -0
- package/geocoding/index.js +278 -0
- package/interactions/detail-model.d.ts +54 -0
- package/interactions/detail-model.d.ts.map +1 -0
- package/interactions/detail-model.js +105 -0
- package/interactions/exploration-bindings.d.ts +120 -0
- package/interactions/exploration-bindings.d.ts.map +1 -0
- package/interactions/exploration-bindings.js +218 -0
- package/interactions/feature-state.d.ts +144 -0
- package/interactions/feature-state.d.ts.map +1 -0
- package/interactions/feature-state.js +169 -0
- package/interactions/hit-test.d.ts +112 -0
- package/interactions/hit-test.d.ts.map +1 -0
- package/interactions/hit-test.js +291 -0
- package/interactions/index.d.ts +31 -0
- package/interactions/index.d.ts.map +1 -0
- package/interactions/index.js +24 -0
- package/interactions/share-state.d.ts +36 -0
- package/interactions/share-state.d.ts.map +1 -0
- package/interactions/share-state.js +123 -0
- package/map/feature-service-adapter.d.ts +138 -0
- package/map/feature-service-adapter.d.ts.map +1 -0
- package/map/feature-service-adapter.js +279 -0
- package/map/honua-map.d.ts +203 -0
- package/map/honua-map.d.ts.map +1 -0
- package/map/honua-map.js +347 -0
- package/map/index.d.ts +27 -0
- package/map/index.d.ts.map +1 -0
- package/map/index.js +22 -0
- package/map/maplibre-target.d.ts +103 -0
- package/map/maplibre-target.d.ts.map +1 -0
- package/map/maplibre-target.js +164 -0
- package/map/webmap-maplibre.d.ts +60 -0
- package/map/webmap-maplibre.d.ts.map +1 -0
- package/map/webmap-maplibre.js +212 -0
- package/operate/client.d.ts +94 -0
- package/operate/client.d.ts.map +1 -0
- package/operate/client.js +361 -0
- package/operate/index.d.ts +22 -0
- package/operate/index.d.ts.map +1 -0
- package/operate/index.js +19 -0
- package/operate/types.d.ts +397 -0
- package/operate/types.d.ts.map +1 -0
- package/operate/types.js +17 -0
- package/operator/client.d.ts +60 -0
- package/operator/client.d.ts.map +1 -0
- package/operator/client.js +20 -0
- package/operator/controllers/approval.d.ts +52 -0
- package/operator/controllers/approval.d.ts.map +1 -0
- package/operator/controllers/approval.js +123 -0
- package/operator/controllers/base.d.ts +27 -0
- package/operator/controllers/base.d.ts.map +1 -0
- package/operator/controllers/base.js +53 -0
- package/operator/controllers/builder-workspace.d.ts +55 -0
- package/operator/controllers/builder-workspace.d.ts.map +1 -0
- package/operator/controllers/builder-workspace.js +108 -0
- package/operator/controllers/chat.d.ts +61 -0
- package/operator/controllers/chat.d.ts.map +1 -0
- package/operator/controllers/chat.js +154 -0
- package/operator/controllers/clarification.d.ts +52 -0
- package/operator/controllers/clarification.d.ts.map +1 -0
- package/operator/controllers/clarification.js +121 -0
- package/operator/controllers/execution.d.ts +60 -0
- package/operator/controllers/execution.d.ts.map +1 -0
- package/operator/controllers/execution.js +286 -0
- package/operator/controllers/index.d.ts +23 -0
- package/operator/controllers/index.d.ts.map +1 -0
- package/operator/controllers/index.js +15 -0
- package/operator/controllers/map-workspace.d.ts +85 -0
- package/operator/controllers/map-workspace.d.ts.map +1 -0
- package/operator/controllers/map-workspace.js +296 -0
- package/operator/controllers/plan-review.d.ts +66 -0
- package/operator/controllers/plan-review.d.ts.map +1 -0
- package/operator/controllers/plan-review.js +124 -0
- package/operator/errors.d.ts +62 -0
- package/operator/errors.d.ts.map +1 -0
- package/operator/errors.js +75 -0
- package/operator/i18n/index.d.ts +10 -0
- package/operator/i18n/index.d.ts.map +1 -0
- package/operator/i18n/index.js +8 -0
- package/operator/i18n/messages.d.ts +19 -0
- package/operator/i18n/messages.d.ts.map +1 -0
- package/operator/i18n/messages.js +54 -0
- package/operator/index.d.ts +19 -0
- package/operator/index.d.ts.map +1 -0
- package/operator/index.js +15 -0
- package/operator/telemetry.d.ts +26 -0
- package/operator/telemetry.d.ts.map +1 -0
- package/operator/telemetry.js +9 -0
- package/operator/theming/index.d.ts +12 -0
- package/operator/theming/index.d.ts.map +1 -0
- package/operator/theming/index.js +9 -0
- package/operator/theming/provider.d.ts +27 -0
- package/operator/theming/provider.d.ts.map +1 -0
- package/operator/theming/provider.js +26 -0
- package/operator/theming/tokens.d.ts +28 -0
- package/operator/theming/tokens.d.ts.map +1 -0
- package/operator/theming/tokens.js +65 -0
- package/operator/workspace/events.d.ts +70 -0
- package/operator/workspace/events.d.ts.map +1 -0
- package/operator/workspace/events.js +9 -0
- package/operator/workspace/index.d.ts +12 -0
- package/operator/workspace/index.d.ts.map +1 -0
- package/operator/workspace/index.js +8 -0
- package/operator/workspace/types.d.ts +178 -0
- package/operator/workspace/types.d.ts.map +1 -0
- package/operator/workspace/types.js +47 -0
- package/operator/workspace/workspace.d.ts +58 -0
- package/operator/workspace/workspace.d.ts.map +1 -0
- package/operator/workspace/workspace.js +339 -0
- package/package.json +105 -0
- package/realtime/exploration.d.ts +16 -0
- package/realtime/exploration.d.ts.map +1 -0
- package/realtime/exploration.js +32 -0
- package/realtime/honua-server.d.ts +123 -0
- package/realtime/honua-server.d.ts.map +1 -0
- package/realtime/honua-server.js +188 -0
- package/realtime/index.d.ts +20 -0
- package/realtime/index.d.ts.map +1 -0
- package/realtime/index.js +14 -0
- package/realtime/projections.d.ts +30 -0
- package/realtime/projections.d.ts.map +1 -0
- package/realtime/projections.js +51 -0
- package/realtime/reducer.d.ts +14 -0
- package/realtime/reducer.d.ts.map +1 -0
- package/realtime/reducer.js +351 -0
- package/realtime/sse.d.ts +23 -0
- package/realtime/sse.d.ts.map +1 -0
- package/realtime/sse.js +143 -0
- package/realtime/store.d.ts +18 -0
- package/realtime/store.d.ts.map +1 -0
- package/realtime/store.js +63 -0
- package/realtime/types.d.ts +190 -0
- package/realtime/types.d.ts.map +1 -0
- package/realtime/types.js +10 -0
- package/replica-sync/client.d.ts +32 -0
- package/replica-sync/client.d.ts.map +1 -0
- package/replica-sync/client.js +52 -0
- package/replica-sync/errors.d.ts +22 -0
- package/replica-sync/errors.d.ts.map +1 -0
- package/replica-sync/errors.js +29 -0
- package/replica-sync/fixture.d.ts +40 -0
- package/replica-sync/fixture.d.ts.map +1 -0
- package/replica-sync/fixture.js +364 -0
- package/replica-sync/index.d.ts +22 -0
- package/replica-sync/index.d.ts.map +1 -0
- package/replica-sync/index.js +17 -0
- package/replica-sync/types.d.ts +270 -0
- package/replica-sync/types.d.ts.map +1 -0
- package/replica-sync/types.js +13 -0
- package/runtime/diff.d.ts +31 -0
- package/runtime/diff.d.ts.map +1 -0
- package/runtime/diff.js +143 -0
- package/runtime/errors.d.ts +40 -0
- package/runtime/errors.d.ts.map +1 -0
- package/runtime/errors.js +35 -0
- package/runtime/index.d.ts +59 -0
- package/runtime/index.d.ts.map +1 -0
- package/runtime/index.js +40 -0
- package/runtime/legend.d.ts +23 -0
- package/runtime/legend.d.ts.map +1 -0
- package/runtime/legend.js +38 -0
- package/runtime/load-package.d.ts +125 -0
- package/runtime/load-package.d.ts.map +1 -0
- package/runtime/load-package.js +272 -0
- package/runtime/map-package-fetch.d.ts +107 -0
- package/runtime/map-package-fetch.d.ts.map +1 -0
- package/runtime/map-package-fetch.js +336 -0
- package/runtime/map-package-realtime.d.ts +169 -0
- package/runtime/map-package-realtime.d.ts.map +1 -0
- package/runtime/map-package-realtime.js +350 -0
- package/runtime/map-package-validation.d.ts +30 -0
- package/runtime/map-package-validation.d.ts.map +1 -0
- package/runtime/map-package-validation.js +257 -0
- package/runtime/map-package-watch.d.ts +78 -0
- package/runtime/map-package-watch.d.ts.map +1 -0
- package/runtime/map-package-watch.js +695 -0
- package/runtime/map-package.d.ts +167 -0
- package/runtime/map-package.d.ts.map +1 -0
- package/runtime/map-package.js +15 -0
- package/runtime/ogc-styles.d.ts +110 -0
- package/runtime/ogc-styles.d.ts.map +1 -0
- package/runtime/ogc-styles.js +195 -0
- package/runtime/pmtiles-protocol.d.ts +77 -0
- package/runtime/pmtiles-protocol.d.ts.map +1 -0
- package/runtime/pmtiles-protocol.js +120 -0
- package/runtime/popups.d.ts +62 -0
- package/runtime/popups.d.ts.map +1 -0
- package/runtime/popups.js +95 -0
- package/runtime/query-tiles.d.ts +217 -0
- package/runtime/query-tiles.d.ts.map +1 -0
- package/runtime/query-tiles.js +801 -0
- package/runtime/runtime.d.ts +243 -0
- package/runtime/runtime.d.ts.map +1 -0
- package/runtime/runtime.js +1147 -0
- package/runtime/source-bridge.d.ts +99 -0
- package/runtime/source-bridge.d.ts.map +1 -0
- package/runtime/source-bridge.js +428 -0
- package/runtime/style-compose.d.ts +46 -0
- package/runtime/style-compose.d.ts.map +1 -0
- package/runtime/style-compose.js +144 -0
- package/runtime/style-interactions.d.ts +141 -0
- package/runtime/style-interactions.d.ts.map +1 -0
- package/runtime/style-interactions.js +574 -0
- package/runtime/style-spec-validation.d.ts +23 -0
- package/runtime/style-spec-validation.d.ts.map +1 -0
- package/runtime/style-spec-validation.js +357 -0
- package/scene-workspace/analysis-widgets.d.ts +334 -0
- package/scene-workspace/analysis-widgets.d.ts.map +1 -0
- package/scene-workspace/analysis-widgets.js +424 -0
- package/scene-workspace/cesium-adapter.d.ts +438 -0
- package/scene-workspace/cesium-adapter.d.ts.map +1 -0
- package/scene-workspace/cesium-adapter.js +493 -0
- package/scene-workspace/index.d.ts +21 -0
- package/scene-workspace/index.d.ts.map +1 -0
- package/scene-workspace/index.js +14 -0
- package/scene-workspace/primitives.d.ts +162 -0
- package/scene-workspace/primitives.d.ts.map +1 -0
- package/scene-workspace/primitives.js +255 -0
- package/scene-workspace/scene-discovery.d.ts +196 -0
- package/scene-workspace/scene-discovery.d.ts.map +1 -0
- package/scene-workspace/scene-discovery.js +228 -0
- package/scene-workspace/scene-view.d.ts +209 -0
- package/scene-workspace/scene-view.d.ts.map +1 -0
- package/scene-workspace/scene-view.js +267 -0
- package/scene-workspace/types.d.ts +229 -0
- package/scene-workspace/types.d.ts.map +1 -0
- package/scene-workspace/types.js +23 -0
- package/scene-workspace/workspace.d.ts +13 -0
- package/scene-workspace/workspace.d.ts.map +1 -0
- package/scene-workspace/workspace.js +391 -0
- package/share/denial.d.ts +78 -0
- package/share/denial.d.ts.map +1 -0
- package/share/denial.js +61 -0
- package/share/embed-token.d.ts +71 -0
- package/share/embed-token.d.ts.map +1 -0
- package/share/embed-token.js +99 -0
- package/share/index.d.ts +35 -0
- package/share/index.d.ts.map +1 -0
- package/share/index.js +30 -0
- package/share/open-data.d.ts +114 -0
- package/share/open-data.d.ts.map +1 -0
- package/share/open-data.js +81 -0
- package/share/types.d.ts +163 -0
- package/share/types.d.ts.map +1 -0
- package/share/types.js +17 -0
- package/studio/capability-manifest.d.ts +285 -0
- package/studio/capability-manifest.d.ts.map +1 -0
- package/studio/capability-manifest.js +59 -0
- package/studio/chart-spec.d.ts +85 -0
- package/studio/chart-spec.d.ts.map +1 -0
- package/studio/chart-spec.js +106 -0
- package/studio/index.d.ts +34 -0
- package/studio/index.d.ts.map +1 -0
- package/studio/index.js +27 -0
- package/studio/provenance.d.ts +131 -0
- package/studio/provenance.d.ts.map +1 -0
- package/studio/provenance.js +39 -0
- package/studio/publish.d.ts +64 -0
- package/studio/publish.d.ts.map +1 -0
- package/studio/publish.js +13 -0
- package/studio/types.d.ts +278 -0
- package/studio/types.d.ts.map +1 -0
- package/studio/types.js +71 -0
- package/studio/validate.d.ts +45 -0
- package/studio/validate.d.ts.map +1 -0
- package/studio/validate.js +255 -0
- package/studio/validation.d.ts +112 -0
- package/studio/validation.d.ts.map +1 -0
- package/studio/validation.js +42 -0
- package/style/factory.d.ts +30 -0
- package/style/factory.d.ts.map +1 -0
- package/style/factory.js +61 -0
- package/style/index.d.ts +25 -0
- package/style/index.d.ts.map +1 -0
- package/style/index.js +24 -0
- package/style/specification.d.ts +203 -0
- package/style/specification.d.ts.map +1 -0
- package/style/specification.js +178 -0
- package/style/wms-wmts-resolvers.d.ts +38 -0
- package/style/wms-wmts-resolvers.d.ts.map +1 -0
- package/style/wms-wmts-resolvers.js +92 -0
- package/web-components/controller.d.ts +39 -0
- package/web-components/controller.d.ts.map +1 -0
- package/web-components/controller.js +640 -0
- package/web-components/elements.d.ts +210 -0
- package/web-components/elements.d.ts.map +1 -0
- package/web-components/elements.js +1651 -0
- package/web-components/index.d.ts +24 -0
- package/web-components/index.d.ts.map +1 -0
- package/web-components/index.js +22 -0
- package/web-components/maplibre-renderer.d.ts +22 -0
- package/web-components/maplibre-renderer.d.ts.map +1 -0
- package/web-components/maplibre-renderer.js +474 -0
- package/web-components/types.d.ts +397 -0
- package/web-components/types.d.ts.map +1 -0
- package/web-components/types.js +1 -0
- package/webmap/contract.d.ts +28 -0
- package/webmap/contract.d.ts.map +1 -0
- package/webmap/contract.js +130 -0
- package/webmap/convert-basemap.d.ts +17 -0
- package/webmap/convert-basemap.d.ts.map +1 -0
- package/webmap/convert-basemap.js +78 -0
- package/webmap/convert-extent.d.ts +17 -0
- package/webmap/convert-extent.d.ts.map +1 -0
- package/webmap/convert-extent.js +114 -0
- package/webmap/convert-label.d.ts +13 -0
- package/webmap/convert-label.d.ts.map +1 -0
- package/webmap/convert-label.js +125 -0
- package/webmap/convert-layer.d.ts +22 -0
- package/webmap/convert-layer.d.ts.map +1 -0
- package/webmap/convert-layer.js +181 -0
- package/webmap/convert-popup.d.ts +34 -0
- package/webmap/convert-popup.d.ts.map +1 -0
- package/webmap/convert-popup.js +68 -0
- package/webmap/convert-renderer.d.ts +17 -0
- package/webmap/convert-renderer.d.ts.map +1 -0
- package/webmap/convert-renderer.js +161 -0
- package/webmap/convert-symbol.d.ts +17 -0
- package/webmap/convert-symbol.d.ts.map +1 -0
- package/webmap/convert-symbol.js +122 -0
- package/webmap/index.d.ts +44 -0
- package/webmap/index.d.ts.map +1 -0
- package/webmap/index.js +33 -0
- package/webmap/parse.d.ts +25 -0
- package/webmap/parse.d.ts.map +1 -0
- package/webmap/parse.js +83 -0
- package/webmap/types.d.ts +264 -0
- package/webmap/types.d.ts.map +1 -0
- package/webmap/types.js +13 -0
- package/webmap/warnings.d.ts +30 -0
- package/webmap/warnings.d.ts.map +1 -0
- package/webmap/warnings.js +37 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import type { IJobRun } from "../contract/jobs.js";
|
|
2
|
+
import type { HonuaOgcProcesses } from "./ogc-processes.js";
|
|
3
|
+
import type { HonuaGeoprocessingService } from "./surfaces.js";
|
|
4
|
+
import type { OgcProcessExecuteRequest } from "./types.js";
|
|
5
|
+
export type HonuaProcessProtocol = "ogc-processes" | "geoservices-gp" | "geospatial-grpc";
|
|
6
|
+
export interface HonuaProcessExecuteRequest {
|
|
7
|
+
/** OGC process id or a human-readable id for GP/gRPC plans. */
|
|
8
|
+
readonly processId?: string;
|
|
9
|
+
/** OGC-style input bag, also used as GPServer submit parameters by the GeoServices adapter. */
|
|
10
|
+
readonly inputs?: OgcProcessExecuteRequest["inputs"];
|
|
11
|
+
/** GeoServices GPServer submit parameters. Takes precedence over `inputs`. */
|
|
12
|
+
readonly parameters?: Record<string, unknown>;
|
|
13
|
+
/** geospatial-grpc `ExecutionPlan` message or compatible plain object. */
|
|
14
|
+
readonly plan?: unknown;
|
|
15
|
+
/** OGC output descriptor map, when targeting OGC API Processes. */
|
|
16
|
+
readonly outputs?: OgcProcessExecuteRequest["outputs"];
|
|
17
|
+
/** geospatial-grpc `ExecutionContext` message or compatible plain object. */
|
|
18
|
+
readonly context?: unknown;
|
|
19
|
+
/** Result ids to fetch when targeting GeoServices GPServer result routes. */
|
|
20
|
+
readonly resultNames?: readonly string[];
|
|
21
|
+
readonly mode?: "async" | "auto";
|
|
22
|
+
readonly signal?: AbortSignal;
|
|
23
|
+
}
|
|
24
|
+
export interface HonuaProcessJobOptions {
|
|
25
|
+
readonly processId?: string;
|
|
26
|
+
readonly resultNames?: readonly string[];
|
|
27
|
+
}
|
|
28
|
+
export interface HonuaProcessAdapter {
|
|
29
|
+
readonly protocol: HonuaProcessProtocol;
|
|
30
|
+
execute<T = unknown>(request: HonuaProcessExecuteRequest): Promise<IJobRun<T>>;
|
|
31
|
+
job<T = unknown>(jobId: string, options?: HonuaProcessJobOptions): IJobRun<T>;
|
|
32
|
+
validate?(request: HonuaProcessExecuteRequest): Promise<unknown>;
|
|
33
|
+
dryRun?(request: HonuaProcessExecuteRequest): Promise<unknown>;
|
|
34
|
+
}
|
|
35
|
+
export declare class HonuaProcessRunner {
|
|
36
|
+
readonly adapter: HonuaProcessAdapter;
|
|
37
|
+
constructor(adapter: HonuaProcessAdapter);
|
|
38
|
+
get protocol(): HonuaProcessProtocol;
|
|
39
|
+
execute<T = unknown>(request: HonuaProcessExecuteRequest): Promise<IJobRun<T>>;
|
|
40
|
+
job<T = unknown>(jobId: string, options?: HonuaProcessJobOptions): IJobRun<T>;
|
|
41
|
+
validate(request: HonuaProcessExecuteRequest): Promise<unknown>;
|
|
42
|
+
dryRun(request: HonuaProcessExecuteRequest): Promise<unknown>;
|
|
43
|
+
}
|
|
44
|
+
export declare function createHonuaProcessRunner(adapter: HonuaProcessAdapter): HonuaProcessRunner;
|
|
45
|
+
export declare function createOgcProcessesAdapter(processes: HonuaOgcProcesses): HonuaProcessAdapter;
|
|
46
|
+
export declare function createGeoServicesGpAdapter(service: HonuaGeoprocessingService): HonuaProcessAdapter;
|
|
47
|
+
export interface GeospatialGrpcProcessClient {
|
|
48
|
+
validatePlan?(request: {
|
|
49
|
+
readonly plan: unknown;
|
|
50
|
+
}): Promise<unknown>;
|
|
51
|
+
dryRunPlan?(request: {
|
|
52
|
+
readonly plan: unknown;
|
|
53
|
+
}): Promise<unknown>;
|
|
54
|
+
submitJob(request: {
|
|
55
|
+
readonly plan: unknown;
|
|
56
|
+
readonly context?: unknown;
|
|
57
|
+
}): Promise<GeospatialGrpcSubmitJobResponse>;
|
|
58
|
+
getJob(request: {
|
|
59
|
+
readonly jobId: string;
|
|
60
|
+
readonly signal?: AbortSignal;
|
|
61
|
+
}): Promise<GeospatialGrpcGetJobResponse>;
|
|
62
|
+
getJobResult(request: {
|
|
63
|
+
readonly jobId: string;
|
|
64
|
+
}): Promise<GeospatialGrpcGetJobResultResponse>;
|
|
65
|
+
cancelJob(request: {
|
|
66
|
+
readonly jobId: string;
|
|
67
|
+
}): Promise<GeospatialGrpcCancelJobResponse>;
|
|
68
|
+
}
|
|
69
|
+
export interface GeospatialGrpcSubmitJobResponse {
|
|
70
|
+
readonly jobId?: string;
|
|
71
|
+
readonly job_id?: string;
|
|
72
|
+
readonly state?: unknown;
|
|
73
|
+
}
|
|
74
|
+
export interface GeospatialGrpcGetJobResponse extends GeospatialGrpcSubmitJobResponse {
|
|
75
|
+
readonly progress?: GeospatialGrpcJobProgress;
|
|
76
|
+
}
|
|
77
|
+
export interface GeospatialGrpcCancelJobResponse extends GeospatialGrpcSubmitJobResponse {
|
|
78
|
+
}
|
|
79
|
+
export interface GeospatialGrpcGetJobResultResponse {
|
|
80
|
+
readonly jobId?: string;
|
|
81
|
+
readonly job_id?: string;
|
|
82
|
+
readonly result?: unknown;
|
|
83
|
+
readonly error?: GeospatialGrpcErrorDetail;
|
|
84
|
+
readonly outcome?: {
|
|
85
|
+
readonly case?: string;
|
|
86
|
+
readonly value?: unknown;
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
export interface GeospatialGrpcJobProgress {
|
|
90
|
+
readonly progressPercent?: number;
|
|
91
|
+
readonly progress_percent?: number;
|
|
92
|
+
readonly message?: string;
|
|
93
|
+
readonly updatedAt?: number | bigint | string;
|
|
94
|
+
readonly updated_at?: number | bigint | string;
|
|
95
|
+
readonly state?: unknown;
|
|
96
|
+
}
|
|
97
|
+
export interface GeospatialGrpcErrorDetail {
|
|
98
|
+
readonly errorCode?: string;
|
|
99
|
+
readonly error_code?: string;
|
|
100
|
+
readonly message?: string;
|
|
101
|
+
readonly details?: Record<string, string>;
|
|
102
|
+
}
|
|
103
|
+
export declare function createGeospatialGrpcProcessAdapter(client: GeospatialGrpcProcessClient): HonuaProcessAdapter;
|
|
104
|
+
//# sourceMappingURL=process-runner.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"process-runner.d.ts","sourceRoot":"","sources":["../../../src/core/process-runner.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EAQR,MAAM,qBAAqB,CAAC;AAE7B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,C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AC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;CACzE;AAED,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,CAAC;IAClC,QAAQ,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IACnC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC;IAC/C,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC3C;AAED,wBAAgB,kCAAkC,CAAC,MAAM,EAAE,2BAA2B,GAAG,mBAAmB,CAmB3G"}
|
|
@@ -0,0 +1,315 @@
|
|
|
1
|
+
import { HonuaJobPollTimeoutError } from "../contract/jobs.js";
|
|
2
|
+
export class HonuaProcessRunner {
|
|
3
|
+
adapter;
|
|
4
|
+
constructor(adapter) {
|
|
5
|
+
this.adapter = adapter;
|
|
6
|
+
}
|
|
7
|
+
get protocol() {
|
|
8
|
+
return this.adapter.protocol;
|
|
9
|
+
}
|
|
10
|
+
execute(request) {
|
|
11
|
+
return this.adapter.execute(request);
|
|
12
|
+
}
|
|
13
|
+
job(jobId, options = {}) {
|
|
14
|
+
return this.adapter.job(jobId, options);
|
|
15
|
+
}
|
|
16
|
+
async validate(request) {
|
|
17
|
+
if (!this.adapter.validate) {
|
|
18
|
+
throw new Error(`${this.protocol} does not expose validate through the unified process runner.`);
|
|
19
|
+
}
|
|
20
|
+
return this.adapter.validate(request);
|
|
21
|
+
}
|
|
22
|
+
async dryRun(request) {
|
|
23
|
+
if (!this.adapter.dryRun) {
|
|
24
|
+
throw new Error(`${this.protocol} does not expose dryRun through the unified process runner.`);
|
|
25
|
+
}
|
|
26
|
+
return this.adapter.dryRun(request);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
export function createHonuaProcessRunner(adapter) {
|
|
30
|
+
return new HonuaProcessRunner(adapter);
|
|
31
|
+
}
|
|
32
|
+
export function createOgcProcessesAdapter(processes) {
|
|
33
|
+
return {
|
|
34
|
+
protocol: "ogc-processes",
|
|
35
|
+
execute(request) {
|
|
36
|
+
if (!request.processId)
|
|
37
|
+
throw new Error("OGC Processes execution requires processId.");
|
|
38
|
+
return processes.execute({
|
|
39
|
+
processId: request.processId,
|
|
40
|
+
inputs: request.inputs,
|
|
41
|
+
outputs: request.outputs,
|
|
42
|
+
mode: request.mode ?? "async",
|
|
43
|
+
signal: request.signal,
|
|
44
|
+
});
|
|
45
|
+
},
|
|
46
|
+
job(jobId, options = {}) {
|
|
47
|
+
return processes.job(jobId, { processId: options.processId });
|
|
48
|
+
},
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
export function createGeoServicesGpAdapter(service) {
|
|
52
|
+
return {
|
|
53
|
+
protocol: "geoservices-gp",
|
|
54
|
+
execute(request) {
|
|
55
|
+
return service.submit({
|
|
56
|
+
parameters: request.parameters ?? request.inputs ?? {},
|
|
57
|
+
signal: request.signal,
|
|
58
|
+
}, { resultNames: request.resultNames });
|
|
59
|
+
},
|
|
60
|
+
job(jobId, options = {}) {
|
|
61
|
+
return service.job(jobId, { resultNames: options.resultNames });
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
export function createGeospatialGrpcProcessAdapter(client) {
|
|
66
|
+
return {
|
|
67
|
+
protocol: "geospatial-grpc",
|
|
68
|
+
validate(request) {
|
|
69
|
+
if (!client.validatePlan)
|
|
70
|
+
throw new Error("geospatial-grpc ProcessService client does not expose validatePlan.");
|
|
71
|
+
return client.validatePlan({ plan: requirePlan(request) });
|
|
72
|
+
},
|
|
73
|
+
dryRun(request) {
|
|
74
|
+
if (!client.dryRunPlan)
|
|
75
|
+
throw new Error("geospatial-grpc ProcessService client does not expose dryRunPlan.");
|
|
76
|
+
return client.dryRunPlan({ plan: requirePlan(request) });
|
|
77
|
+
},
|
|
78
|
+
async execute(request) {
|
|
79
|
+
const accepted = await client.submitJob({ plan: requirePlan(request), context: request.context });
|
|
80
|
+
return new GeospatialGrpcProcessJobRun({ client, accepted });
|
|
81
|
+
},
|
|
82
|
+
job(jobId) {
|
|
83
|
+
return new GeospatialGrpcProcessJobRun({ client, accepted: { jobId, state: "JOB_STATE_UNSPECIFIED" } });
|
|
84
|
+
},
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
class GeospatialGrpcProcessJobRun {
|
|
88
|
+
id;
|
|
89
|
+
type = "geospatial-grpc";
|
|
90
|
+
client;
|
|
91
|
+
currentStatus;
|
|
92
|
+
currentProgress;
|
|
93
|
+
terminalSnapshot;
|
|
94
|
+
terminalPromise;
|
|
95
|
+
listeners = new Set();
|
|
96
|
+
constructor(options) {
|
|
97
|
+
this.client = options.client;
|
|
98
|
+
this.id = readJobId(options.accepted);
|
|
99
|
+
this.currentStatus = geospatialGrpcJobStateToStatus(options.accepted.state);
|
|
100
|
+
}
|
|
101
|
+
get status() {
|
|
102
|
+
return this.currentStatus;
|
|
103
|
+
}
|
|
104
|
+
get progress() {
|
|
105
|
+
return this.currentProgress;
|
|
106
|
+
}
|
|
107
|
+
async poll() {
|
|
108
|
+
if (this.terminalSnapshot)
|
|
109
|
+
return this.terminalSnapshot;
|
|
110
|
+
const response = await this.client.getJob({ jobId: this.id });
|
|
111
|
+
return this.handleJob(response);
|
|
112
|
+
}
|
|
113
|
+
watch(listener) {
|
|
114
|
+
this.listeners.add(listener);
|
|
115
|
+
return () => this.listeners.delete(listener);
|
|
116
|
+
}
|
|
117
|
+
async results(options = {}) {
|
|
118
|
+
if (!this.terminalPromise) {
|
|
119
|
+
// Reset on failure so an aborted / timed-out poll does not permanently
|
|
120
|
+
// poison subsequent results() calls.
|
|
121
|
+
this.terminalPromise = this.runUntilTerminal(options).catch((error) => {
|
|
122
|
+
this.terminalPromise = undefined;
|
|
123
|
+
throw error;
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
return this.terminalPromise;
|
|
127
|
+
}
|
|
128
|
+
async cancel() {
|
|
129
|
+
if (this.terminalSnapshot)
|
|
130
|
+
return this.currentStatus;
|
|
131
|
+
const response = await this.client.cancelJob({ jobId: this.id });
|
|
132
|
+
const snapshot = await this.handleJob(response);
|
|
133
|
+
return snapshot.status;
|
|
134
|
+
}
|
|
135
|
+
async runUntilTerminal(options = {}) {
|
|
136
|
+
const { signal } = options;
|
|
137
|
+
const baseIntervalMs = options.pollIntervalMs ?? 1_000;
|
|
138
|
+
const maxIntervalMs = options.maxPollIntervalMs ?? Math.max(baseIntervalMs, 30_000);
|
|
139
|
+
const startedAt = Date.now();
|
|
140
|
+
let attempts = 0;
|
|
141
|
+
while (!this.terminalSnapshot) {
|
|
142
|
+
if (signal?.aborted) {
|
|
143
|
+
throw new HonuaJobPollTimeoutError(`Job ${this.id} poll aborted`, "aborted", this.id, this.currentStatus);
|
|
144
|
+
}
|
|
145
|
+
if (options.maxAttempts !== undefined && attempts >= options.maxAttempts) {
|
|
146
|
+
throw new HonuaJobPollTimeoutError(`Job ${this.id} did not reach a terminal state within ${options.maxAttempts} poll attempt(s)`, "max-attempts", this.id, this.currentStatus);
|
|
147
|
+
}
|
|
148
|
+
let response;
|
|
149
|
+
try {
|
|
150
|
+
response = await this.client.getJob({ jobId: this.id, signal });
|
|
151
|
+
}
|
|
152
|
+
catch (error) {
|
|
153
|
+
if (signal?.aborted) {
|
|
154
|
+
throw new HonuaJobPollTimeoutError(`Job ${this.id} poll aborted`, "aborted", this.id, this.currentStatus);
|
|
155
|
+
}
|
|
156
|
+
throw error;
|
|
157
|
+
}
|
|
158
|
+
attempts += 1;
|
|
159
|
+
await this.handleJob(response);
|
|
160
|
+
if (this.terminalSnapshot)
|
|
161
|
+
break;
|
|
162
|
+
if (options.deadlineMs !== undefined && Date.now() - startedAt >= options.deadlineMs) {
|
|
163
|
+
throw new HonuaJobPollTimeoutError(`Job ${this.id} did not reach a terminal state within ${options.deadlineMs}ms`, "deadline", this.id, this.currentStatus);
|
|
164
|
+
}
|
|
165
|
+
// Capped exponential backoff instead of a fixed 1s interval.
|
|
166
|
+
const intervalMs = Math.min(maxIntervalMs, baseIntervalMs * 2 ** (attempts - 1));
|
|
167
|
+
if (intervalMs > 0) {
|
|
168
|
+
await wait(intervalMs, signal);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
if (this.terminalSnapshot.status === "successful" && this.terminalSnapshot.result) {
|
|
172
|
+
return this.terminalSnapshot.result;
|
|
173
|
+
}
|
|
174
|
+
throw new Error(this.terminalSnapshot.error?.message ?? `geospatial-grpc job ended in ${this.terminalSnapshot.status}`);
|
|
175
|
+
}
|
|
176
|
+
async handleJob(response) {
|
|
177
|
+
const jobProgress = "progress" in response ? response.progress : undefined;
|
|
178
|
+
const status = geospatialGrpcJobStateToStatus(response.state ?? jobProgress?.state);
|
|
179
|
+
const progress = geospatialGrpcProgress(jobProgress);
|
|
180
|
+
this.currentStatus = status;
|
|
181
|
+
this.currentProgress = progress;
|
|
182
|
+
if (status === "successful") {
|
|
183
|
+
const result = await this.client.getJobResult({ jobId: this.id });
|
|
184
|
+
const snapshot = geospatialGrpcResultSnapshot(result, progress);
|
|
185
|
+
this.terminalSnapshot = snapshot;
|
|
186
|
+
this.currentStatus = snapshot.status;
|
|
187
|
+
this.notify(snapshot);
|
|
188
|
+
return snapshot;
|
|
189
|
+
}
|
|
190
|
+
if (status === "failed" || status === "dismissed") {
|
|
191
|
+
const result = await this.safeGetTerminalResult();
|
|
192
|
+
const error = result ? geospatialGrpcError(result) : undefined;
|
|
193
|
+
const snapshot = { status, progress, ...(error ? { error } : {}) };
|
|
194
|
+
this.terminalSnapshot = snapshot;
|
|
195
|
+
this.notify(snapshot);
|
|
196
|
+
return snapshot;
|
|
197
|
+
}
|
|
198
|
+
const snapshot = { status, progress };
|
|
199
|
+
this.notify(snapshot);
|
|
200
|
+
return snapshot;
|
|
201
|
+
}
|
|
202
|
+
async safeGetTerminalResult() {
|
|
203
|
+
try {
|
|
204
|
+
return await this.client.getJobResult({ jobId: this.id });
|
|
205
|
+
}
|
|
206
|
+
catch {
|
|
207
|
+
return undefined;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
notify(snapshot) {
|
|
211
|
+
for (const listener of this.listeners)
|
|
212
|
+
listener(snapshot);
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
function requirePlan(request) {
|
|
216
|
+
if (request.plan === undefined)
|
|
217
|
+
throw new Error("geospatial-grpc process execution requires plan.");
|
|
218
|
+
return request.plan;
|
|
219
|
+
}
|
|
220
|
+
function readJobId(response) {
|
|
221
|
+
const jobId = response.jobId ?? response.job_id;
|
|
222
|
+
if (!jobId)
|
|
223
|
+
throw new Error("ProcessService response did not include jobId.");
|
|
224
|
+
return jobId;
|
|
225
|
+
}
|
|
226
|
+
function geospatialGrpcJobStateToStatus(value) {
|
|
227
|
+
if (value === 6)
|
|
228
|
+
return "successful";
|
|
229
|
+
if (value === 7)
|
|
230
|
+
return "failed";
|
|
231
|
+
if (value === 8)
|
|
232
|
+
return "dismissed";
|
|
233
|
+
if (value === 5)
|
|
234
|
+
return "running";
|
|
235
|
+
if (value === 1 || value === 2 || value === 3 || value === 4)
|
|
236
|
+
return "accepted";
|
|
237
|
+
const normalized = String(value ?? "").toLowerCase();
|
|
238
|
+
if (normalized.includes("completed") || normalized === "successful")
|
|
239
|
+
return "successful";
|
|
240
|
+
if (normalized.includes("failed"))
|
|
241
|
+
return "failed";
|
|
242
|
+
if (normalized.includes("cancelled") || normalized.includes("canceled") || normalized.includes("dismissed")) {
|
|
243
|
+
return "dismissed";
|
|
244
|
+
}
|
|
245
|
+
if (normalized.includes("draft") ||
|
|
246
|
+
normalized.includes("clarification") ||
|
|
247
|
+
normalized.includes("validated") ||
|
|
248
|
+
normalized.includes("approval") ||
|
|
249
|
+
normalized.includes("accepted")) {
|
|
250
|
+
return "accepted";
|
|
251
|
+
}
|
|
252
|
+
if (normalized.includes("running"))
|
|
253
|
+
return "running";
|
|
254
|
+
return "accepted";
|
|
255
|
+
}
|
|
256
|
+
function geospatialGrpcProgress(progress) {
|
|
257
|
+
if (!progress)
|
|
258
|
+
return undefined;
|
|
259
|
+
const percent = progress.progressPercent ?? progress.progress_percent;
|
|
260
|
+
const updatedAt = progress.updatedAt ?? progress.updated_at;
|
|
261
|
+
const out = {};
|
|
262
|
+
if (typeof percent === "number" && Number.isFinite(percent))
|
|
263
|
+
out.percent = Math.max(0, Math.min(100, percent));
|
|
264
|
+
if (progress.message)
|
|
265
|
+
out.message = progress.message;
|
|
266
|
+
if (updatedAt !== undefined)
|
|
267
|
+
out.updatedAt = timestampToIso(updatedAt);
|
|
268
|
+
return out.percent === undefined && out.message === undefined && out.updatedAt === undefined ? undefined : out;
|
|
269
|
+
}
|
|
270
|
+
function geospatialGrpcResultSnapshot(response, progress) {
|
|
271
|
+
const error = geospatialGrpcError(response);
|
|
272
|
+
if (error)
|
|
273
|
+
return { status: "failed", progress, error };
|
|
274
|
+
return {
|
|
275
|
+
status: "successful",
|
|
276
|
+
progress,
|
|
277
|
+
result: {
|
|
278
|
+
outputs: { result: (response.result ?? response.outcome?.value ?? response) },
|
|
279
|
+
},
|
|
280
|
+
};
|
|
281
|
+
}
|
|
282
|
+
function geospatialGrpcError(response) {
|
|
283
|
+
const candidate = response.error ??
|
|
284
|
+
(response.outcome?.case === "error" ? response.outcome.value : undefined);
|
|
285
|
+
if (!candidate)
|
|
286
|
+
return undefined;
|
|
287
|
+
return {
|
|
288
|
+
code: candidate.errorCode ?? candidate.error_code ?? "GeospatialGrpcProcessError",
|
|
289
|
+
message: candidate.message ?? "geospatial-grpc process execution failed.",
|
|
290
|
+
details: candidate.details,
|
|
291
|
+
};
|
|
292
|
+
}
|
|
293
|
+
function timestampToIso(value) {
|
|
294
|
+
const numeric = typeof value === "bigint" ? Number(value) : typeof value === "string" ? Number(value) : value;
|
|
295
|
+
if (Number.isFinite(numeric))
|
|
296
|
+
return new Date(numeric).toISOString();
|
|
297
|
+
return String(value);
|
|
298
|
+
}
|
|
299
|
+
function wait(ms, signal) {
|
|
300
|
+
return new Promise((resolve) => {
|
|
301
|
+
if (signal?.aborted) {
|
|
302
|
+
resolve();
|
|
303
|
+
return;
|
|
304
|
+
}
|
|
305
|
+
const onAbort = () => {
|
|
306
|
+
clearTimeout(timer);
|
|
307
|
+
resolve();
|
|
308
|
+
};
|
|
309
|
+
const timer = setTimeout(() => {
|
|
310
|
+
signal?.removeEventListener("abort", onAbort);
|
|
311
|
+
resolve();
|
|
312
|
+
}, ms);
|
|
313
|
+
signal?.addEventListener("abort", onAbort, { once: true });
|
|
314
|
+
});
|
|
315
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Low-level transport surface consumed by the per-protocol wire modules.
|
|
3
|
+
*
|
|
4
|
+
* `HonuaClient` owns the request/retry/auth/cache pipeline (see
|
|
5
|
+
* `executeRequest` and `request-pipeline.ts`); each protocol family
|
|
6
|
+
* (OGC API Features/Tiles/Maps/Records/Processes, STAC, WMS, WMTS, and the
|
|
7
|
+
* GeoServices map/feature endpoints) builds its own URLs, serializes its own
|
|
8
|
+
* params, and parses its own responses against this injected transport rather
|
|
9
|
+
* than reaching into the client. The client exposes a single object that
|
|
10
|
+
* satisfies this interface and hands it to the wire functions, keeping the
|
|
11
|
+
* client a thin facade over the protocol modules.
|
|
12
|
+
*
|
|
13
|
+
* @module
|
|
14
|
+
*/
|
|
15
|
+
import type { HonuaMetadataRequestOptions } from "./cache-state.js";
|
|
16
|
+
import type { QueryMethod } from "./types.js";
|
|
17
|
+
/**
|
|
18
|
+
* The minimal request primitives a protocol wire module needs. Every method
|
|
19
|
+
* routes through the same auth / retry / timeout / interceptor pipeline as the
|
|
20
|
+
* rest of the SDK; wire modules never call `fetch` directly.
|
|
21
|
+
*/
|
|
22
|
+
export interface HonuaProtocolTransport {
|
|
23
|
+
/**
|
|
24
|
+
* Normalized base URL (trailing slashes trimmed). Pure URL-template builders
|
|
25
|
+
* (e.g. MapLibre tile sources) read this to produce the same origin/base path
|
|
26
|
+
* the server is served from.
|
|
27
|
+
*/
|
|
28
|
+
readonly baseUrl: string;
|
|
29
|
+
/**
|
|
30
|
+
* Pipeline-aware JSON request. Sends `Accept: application/json` by default and
|
|
31
|
+
* surfaces GeoServices `{error}` envelopes returned on HTTP 200 as
|
|
32
|
+
* `HonuaHttpError`. Caller-supplied query params belong on `path`.
|
|
33
|
+
*/
|
|
34
|
+
requestJson<T = unknown>(method: QueryMethod, path: string, init?: RequestInit, signal?: AbortSignal): Promise<T>;
|
|
35
|
+
/**
|
|
36
|
+
* Fetch a text response (XML / JSON / plain) with explicit Accept negotiation.
|
|
37
|
+
* Used by the WMS / WMTS capabilities pipelines and the WFS adapter.
|
|
38
|
+
*/
|
|
39
|
+
requestText(method: QueryMethod, path: string, options?: {
|
|
40
|
+
accept?: string;
|
|
41
|
+
contentType?: string;
|
|
42
|
+
body?: BodyInit;
|
|
43
|
+
signal?: AbortSignal;
|
|
44
|
+
}): Promise<{
|
|
45
|
+
text: string;
|
|
46
|
+
contentType: string;
|
|
47
|
+
status: number;
|
|
48
|
+
}>;
|
|
49
|
+
/**
|
|
50
|
+
* Fetch a binary response (raw bytes plus content type). Used by the OGC API
|
|
51
|
+
* Tiles / Maps and WMS / WMTS wire methods that negotiate non-JSON formats.
|
|
52
|
+
*/
|
|
53
|
+
requestBytes(method: QueryMethod, path: string, accept: string | undefined, init?: RequestInit, signal?: AbortSignal): Promise<{
|
|
54
|
+
bytes: Uint8Array;
|
|
55
|
+
contentType: string;
|
|
56
|
+
empty: boolean;
|
|
57
|
+
}>;
|
|
58
|
+
/**
|
|
59
|
+
* Cached metadata GET. Honors the metadata cache (`hit`/`miss`/`stale`/
|
|
60
|
+
* `refreshed`/`bypass`), conditional revalidation, and stale-if-error.
|
|
61
|
+
*/
|
|
62
|
+
requestCachedMetadataJson<T>(cacheKey: string, path: string, options?: HonuaMetadataRequestOptions): Promise<T>;
|
|
63
|
+
/**
|
|
64
|
+
* Pipeline-aware request returning the raw, unconsumed `Response` after the
|
|
65
|
+
* shared pipeline succeeds. Callers pick `.json()` / `.text()` / `.arrayBuffer()`.
|
|
66
|
+
*/
|
|
67
|
+
pipelineFetch(method: QueryMethod, path: string, init?: RequestInit, callerSignal?: AbortSignal, options?: {
|
|
68
|
+
okStatuses?: readonly number[];
|
|
69
|
+
}): Promise<Response>;
|
|
70
|
+
/**
|
|
71
|
+
* Request a PBF binary response and decode it, transparently falling back to
|
|
72
|
+
* `f=json` on decode failure. Used by the GeoServices feature query fast path.
|
|
73
|
+
*/
|
|
74
|
+
requestBinaryWithJsonFallback<T = unknown>(method: QueryMethod, path: string, params: URLSearchParams, signal?: AbortSignal): Promise<T>;
|
|
75
|
+
}
|
|
76
|
+
//# sourceMappingURL=protocol-transport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"protocol-transport.d.ts","sourceRoot":"","sources":["../../../src/core/protocol-transport.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,kBAAkB,CAAC;AACpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACrC;;;;OAIG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC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;KAAE,GAC3C,OAAO,CAAC,QAAQ,CAAC,CAAC;IAErB;;;OAGG;IACH,6BAA6B,CAAC,CAAC,GAAG,OAAO,EACvC,MAAM,EAAE,WAAW,EACnB,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,eAAe,EACvB,MAAM,CAAC,EAAE,WAAW,GACnB,OAAO,CAAC,CAAC,CAAC,CAAC;CACf"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Low-level transport surface consumed by the per-protocol wire modules.
|
|
3
|
+
*
|
|
4
|
+
* `HonuaClient` owns the request/retry/auth/cache pipeline (see
|
|
5
|
+
* `executeRequest` and `request-pipeline.ts`); each protocol family
|
|
6
|
+
* (OGC API Features/Tiles/Maps/Records/Processes, STAC, WMS, WMTS, and the
|
|
7
|
+
* GeoServices map/feature endpoints) builds its own URLs, serializes its own
|
|
8
|
+
* params, and parses its own responses against this injected transport rather
|
|
9
|
+
* than reaching into the client. The client exposes a single object that
|
|
10
|
+
* satisfies this interface and hands it to the wire functions, keeping the
|
|
11
|
+
* client a thin facade over the protocol modules.
|
|
12
|
+
*
|
|
13
|
+
* @module
|
|
14
|
+
*/
|
|
15
|
+
export {};
|