@loaders.gl/core 5.0.0-beta.10 → 5.0.0-beta.12

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.
Files changed (441) hide show
  1. package/SCAN-README.md +2 -2
  2. package/SCHEMA-UTILS-README.md +1 -1
  3. package/dist/arrow-geometry/binary-features.cjs +4 -1
  4. package/dist/arrow-geometry/binary-features.cjs.map +2 -2
  5. package/dist/arrow-geometry/binary-features.d.ts.map +1 -1
  6. package/dist/arrow-geometry/binary-features.js +1 -1
  7. package/dist/arrow-geometry/binary-features.js.map +1 -1
  8. package/dist/arrow-geometry/binary-geometry-to-wkb.cjs +2 -2
  9. package/dist/arrow-geometry/binary-geometry-to-wkb.cjs.map +2 -2
  10. package/dist/arrow-geometry/binary-geometry-to-wkb.js +1 -1
  11. package/dist/arrow-geometry/binary-geometry-to-wkb.js.map +1 -1
  12. package/dist/arrow-geometry/feature-collection-to-arrow.cjs +1 -5
  13. package/dist/arrow-geometry/feature-collection-to-arrow.cjs.map +2 -2
  14. package/dist/arrow-geometry/feature-collection-to-arrow.d.ts +4 -3
  15. package/dist/arrow-geometry/feature-collection-to-arrow.d.ts.map +1 -1
  16. package/dist/arrow-geometry/feature-collection-to-arrow.js +2 -6
  17. package/dist/arrow-geometry/feature-collection-to-arrow.js.map +1 -1
  18. package/dist/arrow-geometry/feature-table.cjs +2 -10
  19. package/dist/arrow-geometry/feature-table.cjs.map +2 -2
  20. package/dist/arrow-geometry/feature-table.d.ts +6 -5
  21. package/dist/arrow-geometry/feature-table.d.ts.map +1 -1
  22. package/dist/arrow-geometry/feature-table.js +5 -13
  23. package/dist/arrow-geometry/feature-table.js.map +1 -1
  24. package/dist/arrow-geometry/geojson-table.cjs +3 -3
  25. package/dist/arrow-geometry/geojson-table.cjs.map +3 -3
  26. package/dist/arrow-geometry/geojson-table.d.ts +1 -1
  27. package/dist/arrow-geometry/geojson-table.d.ts.map +1 -1
  28. package/dist/arrow-geometry/geojson-table.js +2 -2
  29. package/dist/arrow-geometry/geojson-table.js.map +1 -1
  30. package/dist/arrow-geometry/geometry-codecs.cjs +6 -6
  31. package/dist/arrow-geometry/geometry-codecs.cjs.map +2 -2
  32. package/dist/arrow-geometry/geometry-codecs.js +1 -1
  33. package/dist/arrow-geometry/geometry-codecs.js.map +1 -1
  34. package/dist/arrow-geometry/geometry-to-wkt.cjs +2 -2
  35. package/dist/arrow-geometry/geometry-to-wkt.cjs.map +2 -2
  36. package/dist/arrow-geometry/geometry-to-wkt.js +1 -1
  37. package/dist/arrow-geometry/geometry-to-wkt.js.map +1 -1
  38. package/dist/arrow-geometry/legacy-binary/convert-flat-geojson-to-binary-features.cjs +3 -1
  39. package/dist/arrow-geometry/legacy-binary/convert-flat-geojson-to-binary-features.cjs.map +2 -2
  40. package/dist/arrow-geometry/legacy-binary/convert-flat-geojson-to-binary-features.js +3 -1
  41. package/dist/arrow-geometry/legacy-binary/convert-flat-geojson-to-binary-features.js.map +1 -1
  42. package/dist/arrow-geometry/wkb-arrow-utils.cjs +1 -5
  43. package/dist/arrow-geometry/wkb-arrow-utils.cjs.map +2 -2
  44. package/dist/arrow-geometry/wkb-arrow-utils.d.ts +7 -7
  45. package/dist/arrow-geometry/wkb-arrow-utils.d.ts.map +1 -1
  46. package/dist/arrow-geometry/wkb-arrow-utils.js +4 -8
  47. package/dist/arrow-geometry/wkb-arrow-utils.js.map +1 -1
  48. package/dist/arrow-geometry/wkb-builder.cjs +3 -3
  49. package/dist/arrow-geometry/wkb-builder.cjs.map +2 -2
  50. package/dist/arrow-geometry/wkb-builder.d.ts +1 -1
  51. package/dist/arrow-geometry/wkb-builder.d.ts.map +1 -1
  52. package/dist/arrow-geometry/wkb-builder.js +1 -1
  53. package/dist/arrow-geometry/wkb-builder.js.map +1 -1
  54. package/dist/arrow-geometry/wkb-statistics.cjs +2 -2
  55. package/dist/arrow-geometry/wkb-statistics.cjs.map +2 -2
  56. package/dist/arrow-geometry/wkb-statistics.js +1 -1
  57. package/dist/arrow-geometry/wkb-statistics.js.map +1 -1
  58. package/dist/arrow-worker-transport.cjs +8 -76
  59. package/dist/arrow-worker-transport.cjs.map +1 -1
  60. package/dist/arrow-worker-transport.d.ts +4 -8
  61. package/dist/arrow-worker-transport.d.ts.map +1 -1
  62. package/dist/arrow-worker-transport.js +15 -89
  63. package/dist/arrow-worker-transport.js.map +1 -1
  64. package/dist/cluster-source.cjs +47 -45
  65. package/dist/cluster-source.cjs.map +2 -2
  66. package/dist/dist.dev.js +71 -60
  67. package/dist/dist.min.js +3 -3
  68. package/dist/federated-table-scan-source.cjs +88 -126
  69. package/dist/federated-table-scan-source.cjs.map +2 -2
  70. package/dist/geoarrow/binary-polygon-to-geoarrow.cjs +2 -2
  71. package/dist/geoarrow/binary-polygon-to-geoarrow.cjs.map +2 -2
  72. package/dist/geoarrow/binary-polygon-to-geoarrow.d.ts +1 -1
  73. package/dist/geoarrow/binary-polygon-to-geoarrow.d.ts.map +1 -1
  74. package/dist/geoarrow/binary-polygon-to-geoarrow.js +1 -1
  75. package/dist/geoarrow/binary-polygon-to-geoarrow.js.map +1 -1
  76. package/dist/geoarrow/clustering/cluster-source.cjs +12 -12
  77. package/dist/geoarrow/clustering/cluster-source.cjs.map +2 -2
  78. package/dist/geoarrow/clustering/cluster-source.d.ts +3 -2
  79. package/dist/geoarrow/clustering/cluster-source.d.ts.map +1 -1
  80. package/dist/geoarrow/clustering/cluster-source.js +12 -14
  81. package/dist/geoarrow/clustering/cluster-source.js.map +1 -1
  82. package/dist/geoarrow/convert-table-to-geoarrow.cjs +4 -12
  83. package/dist/geoarrow/convert-table-to-geoarrow.cjs.map +2 -2
  84. package/dist/geoarrow/convert-table-to-geoarrow.d.ts +5 -5
  85. package/dist/geoarrow/convert-table-to-geoarrow.d.ts.map +1 -1
  86. package/dist/geoarrow/convert-table-to-geoarrow.js +6 -14
  87. package/dist/geoarrow/convert-table-to-geoarrow.js.map +1 -1
  88. package/dist/geoarrow/geoarrow-bounds.cjs +7 -7
  89. package/dist/geoarrow/geoarrow-bounds.cjs.map +3 -3
  90. package/dist/geoarrow/geoarrow-bounds.js +3 -3
  91. package/dist/geoarrow/geoarrow-bounds.js.map +1 -1
  92. package/dist/geoarrow/geoarrow-capabilities.cjs +2 -2
  93. package/dist/geoarrow/geoarrow-capabilities.cjs.map +2 -2
  94. package/dist/geoarrow/geoarrow-capabilities.js +1 -1
  95. package/dist/geoarrow/geoarrow-capabilities.js.map +1 -1
  96. package/dist/geoarrow/geoarrow-converter/convert-geoarrow-geometry.cjs +8 -8
  97. package/dist/geoarrow/geoarrow-converter/convert-geoarrow-geometry.cjs.map +3 -3
  98. package/dist/geoarrow/geoarrow-converter/convert-geoarrow-geometry.d.ts.map +1 -1
  99. package/dist/geoarrow/geoarrow-converter/convert-geoarrow-geometry.js +2 -2
  100. package/dist/geoarrow/geoarrow-converter/convert-geoarrow-geometry.js.map +1 -1
  101. package/dist/geoarrow/geoarrow-converter/convert-geoarrow.cjs +1 -1
  102. package/dist/geoarrow/geoarrow-converter/convert-geoarrow.cjs.map +2 -2
  103. package/dist/geoarrow/geoarrow-converter/convert-geoarrow.js +2 -2
  104. package/dist/geoarrow/geoarrow-converter/convert-geoarrow.js.map +1 -1
  105. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.cjs +2 -3
  106. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.cjs.map +2 -2
  107. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.d.ts +3 -3
  108. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.d.ts.map +1 -1
  109. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.js +2 -3
  110. package/dist/geoarrow/geoarrow-converter/geoarrow-converter.js.map +1 -1
  111. package/dist/geoarrow/geoarrow-inspection.cjs +2 -2
  112. package/dist/geoarrow/geoarrow-inspection.cjs.map +2 -2
  113. package/dist/geoarrow/geoarrow-inspection.js +1 -1
  114. package/dist/geoarrow/geoarrow-inspection.js.map +1 -1
  115. package/dist/geoarrow/geoarrow-stream.cjs +10 -11
  116. package/dist/geoarrow/geoarrow-stream.cjs.map +2 -2
  117. package/dist/geoarrow/geoarrow-stream.d.ts +2 -2
  118. package/dist/geoarrow/geoarrow-stream.d.ts.map +1 -1
  119. package/dist/geoarrow/geoarrow-stream.js +9 -12
  120. package/dist/geoarrow/geoarrow-stream.js.map +1 -1
  121. package/dist/geoarrow/get-geoarrow-vertex-count.cjs +2 -2
  122. package/dist/geoarrow/get-geoarrow-vertex-count.cjs.map +2 -2
  123. package/dist/geoarrow/get-geoarrow-vertex-count.js +1 -1
  124. package/dist/geoarrow/get-geoarrow-vertex-count.js.map +1 -1
  125. package/dist/geoarrow/lib/feature-collection-converters/convert-arrow-binary-feature-collection.cjs.map +1 -1
  126. package/dist/geoarrow/lib/feature-collection-converters/convert-arrow-binary-feature-collection.js +3 -3
  127. package/dist/geoarrow/lib/feature-collection-converters/convert-arrow-binary-feature-collection.js.map +1 -1
  128. package/dist/geoarrow/lib/feature-collection-converters/convert-geometry-column-to-binary-feature-collection.cjs +5 -2
  129. package/dist/geoarrow/lib/feature-collection-converters/convert-geometry-column-to-binary-feature-collection.cjs.map +2 -2
  130. package/dist/geoarrow/lib/feature-collection-converters/convert-geometry-column-to-binary-feature-collection.js +2 -2
  131. package/dist/geoarrow/lib/feature-collection-converters/convert-geometry-column-to-binary-feature-collection.js.map +1 -1
  132. package/dist/geoarrow/lib/geometry-converters/wkb/convert-wkb-to-binary-geometry.cjs +4 -4
  133. package/dist/geoarrow/lib/geometry-converters/wkb/convert-wkb-to-binary-geometry.cjs.map +2 -2
  134. package/dist/geoarrow/lib/geometry-converters/wkb/convert-wkb-to-binary-geometry.js +1 -1
  135. package/dist/geoarrow/lib/geometry-converters/wkb/convert-wkb-to-binary-geometry.js.map +1 -1
  136. package/dist/geoarrow/lib/geometry-converters/wkb/helpers/parse-wkb-header.cjs +3 -3
  137. package/dist/geoarrow/lib/geometry-converters/wkb/helpers/parse-wkb-header.cjs.map +2 -2
  138. package/dist/geoarrow/lib/geometry-converters/wkb/helpers/parse-wkb-header.js +1 -1
  139. package/dist/geoarrow/lib/geometry-converters/wkb/helpers/parse-wkb-header.js.map +1 -1
  140. package/dist/geoarrow/lib/kernels/encode-geoarrow-box.cjs +3 -3
  141. package/dist/geoarrow/lib/kernels/encode-geoarrow-box.cjs.map +2 -2
  142. package/dist/geoarrow/lib/kernels/encode-geoarrow-box.js +1 -1
  143. package/dist/geoarrow/lib/kernels/encode-geoarrow-box.js.map +1 -1
  144. package/dist/geoarrow/lib/table-converters/convert-geoarrow-table.cjs.map +2 -2
  145. package/dist/geoarrow/lib/table-converters/convert-geoarrow-table.d.ts +5 -2
  146. package/dist/geoarrow/lib/table-converters/convert-geoarrow-table.d.ts.map +1 -1
  147. package/dist/geoarrow/lib/table-converters/convert-geoarrow-table.js.map +1 -1
  148. package/dist/geoarrow/mesharrow/arrow-fixed-size-list-utils.cjs +1 -1
  149. package/dist/geoarrow/mesharrow/arrow-fixed-size-list-utils.cjs.map +1 -1
  150. package/dist/geoarrow/mesharrow/arrow-fixed-size-list-utils.js +1 -1
  151. package/dist/geoarrow/mesharrow/arrow-fixed-size-list-utils.js.map +1 -1
  152. package/dist/index.cjs +69 -54
  153. package/dist/index.cjs.map +3 -3
  154. package/dist/index.d.ts +1 -1
  155. package/dist/index.d.ts.map +1 -1
  156. package/dist/index.js +1 -1
  157. package/dist/index.js.map +1 -1
  158. package/dist/lib/api/load.d.ts.map +1 -1
  159. package/dist/lib/api/load.js +2 -4
  160. package/dist/lib/api/load.js.map +1 -1
  161. package/dist/lib/api/loader-options.d.ts +6 -0
  162. package/dist/lib/api/loader-options.d.ts.map +1 -1
  163. package/dist/lib/api/loader-options.js +48 -0
  164. package/dist/lib/api/loader-options.js.map +1 -1
  165. package/dist/lib/api/parse-file.d.ts.map +1 -1
  166. package/dist/lib/api/parse-file.js +2 -5
  167. package/dist/lib/api/parse-file.js.map +1 -1
  168. package/dist/lib/api/parse-in-batches.js +6 -10
  169. package/dist/lib/api/parse-in-batches.js.map +1 -1
  170. package/dist/lib/api/parse-sync.d.ts.map +1 -1
  171. package/dist/lib/api/parse-sync.js +2 -5
  172. package/dist/lib/api/parse-sync.js.map +1 -1
  173. package/dist/lib/api/parse.d.ts.map +1 -1
  174. package/dist/lib/api/parse.js +2 -5
  175. package/dist/lib/api/parse.js.map +1 -1
  176. package/dist/lib/init.js +1 -1
  177. package/dist/lib/loader-utils/native-arrow.d.ts +5 -8
  178. package/dist/lib/loader-utils/native-arrow.d.ts.map +1 -1
  179. package/dist/lib/loader-utils/native-arrow.js +13 -31
  180. package/dist/lib/loader-utils/native-arrow.js.map +1 -1
  181. package/dist/loader-utils/index.cjs +48 -31
  182. package/dist/loader-utils/index.cjs.map +1 -1
  183. package/dist/loader-utils/index.d.ts +1 -1
  184. package/dist/loader-utils/index.d.ts.map +1 -1
  185. package/dist/loader-utils/index.js +1 -1
  186. package/dist/loader-utils/index.js.map +1 -1
  187. package/dist/loader-utils/json-loader.js +1 -1
  188. package/dist/loader-utils/lib/log-utils/log.js +1 -1
  189. package/dist/loader-utils/lib/scan-utils/scan-query-metadata.d.ts +6 -2
  190. package/dist/loader-utils/lib/scan-utils/scan-query-metadata.d.ts.map +1 -1
  191. package/dist/loader-utils/lib/scan-utils/scan-query-metadata.js +1 -0
  192. package/dist/loader-utils/lib/scan-utils/scan-query-metadata.js.map +1 -1
  193. package/dist/loader-utils/lib/scan-utils/table-scan-batch.d.ts +15 -12
  194. package/dist/loader-utils/lib/scan-utils/table-scan-batch.d.ts.map +1 -1
  195. package/dist/loader-utils/lib/scan-utils/table-scan-batch.js +36 -22
  196. package/dist/loader-utils/lib/scan-utils/table-scan-batch.js.map +1 -1
  197. package/dist/loader-utils/lib/sources/table-source-collection.d.ts +2 -1
  198. package/dist/loader-utils/lib/sources/table-source-collection.d.ts.map +1 -1
  199. package/dist/loader-utils/lib/sources/tile-grid.d.ts +6 -1
  200. package/dist/loader-utils/lib/sources/tile-grid.d.ts.map +1 -1
  201. package/dist/loader-utils/lib/sources/tile-grid.js +32 -14
  202. package/dist/loader-utils/lib/sources/tile-grid.js.map +1 -1
  203. package/dist/loader-utils/lib/sources/vector-tile-source.d.ts +3 -3
  204. package/dist/loader-utils/lib/sources/vector-tile-source.d.ts.map +1 -1
  205. package/dist/loader-utils/loader-types.d.ts +3 -5
  206. package/dist/loader-utils/loader-types.d.ts.map +1 -1
  207. package/dist/loader-utils/tile-grid.cjs +21 -9
  208. package/dist/loader-utils/tile-grid.cjs.map +1 -1
  209. package/dist/null-loader.js +1 -1
  210. package/dist/null-worker-node.js +1 -1
  211. package/dist/null-worker.js +1 -1
  212. package/dist/scan/arrow-execution/expressions.cjs +4 -4
  213. package/dist/scan/arrow-execution/expressions.cjs.map +2 -2
  214. package/dist/scan/arrow-execution/expressions.d.ts +4 -4
  215. package/dist/scan/arrow-execution/expressions.d.ts.map +1 -1
  216. package/dist/scan/arrow-execution/expressions.js +4 -4
  217. package/dist/scan/arrow-execution/expressions.js.map +1 -1
  218. package/dist/scan/arrow-execution/filter-arrow-table.cjs +1 -1
  219. package/dist/scan/arrow-execution/filter-arrow-table.cjs.map +1 -1
  220. package/dist/scan/arrow-execution/filter-arrow-table.js +1 -1
  221. package/dist/scan/arrow-execution/filter-arrow-table.js.map +1 -1
  222. package/dist/scan/arrow-query-worker-entry.cjs +121 -0
  223. package/dist/scan/arrow-query-worker-entry.cjs.map +7 -0
  224. package/dist/scan/arrow-query-worker-entry.d.ts +2 -0
  225. package/dist/scan/arrow-query-worker-entry.d.ts.map +1 -0
  226. package/dist/scan/arrow-query-worker-entry.js +7 -0
  227. package/dist/scan/arrow-query-worker-entry.js.map +1 -0
  228. package/dist/scan/arrow-query-worker.cjs +197 -0
  229. package/dist/scan/arrow-query-worker.cjs.map +7 -0
  230. package/dist/scan/arrow-query-worker.d.ts +47 -0
  231. package/dist/scan/arrow-query-worker.d.ts.map +1 -0
  232. package/dist/scan/arrow-query-worker.js +101 -0
  233. package/dist/scan/arrow-query-worker.js.map +1 -0
  234. package/dist/scan/federated-table-scan-source.cjs +12 -13
  235. package/dist/scan/federated-table-scan-source.cjs.map +2 -2
  236. package/dist/scan/federated-table-scan-source.d.ts.map +1 -1
  237. package/dist/scan/federated-table-scan-source.js +14 -15
  238. package/dist/scan/federated-table-scan-source.js.map +1 -1
  239. package/dist/scan/index.cjs +5 -2
  240. package/dist/scan/index.cjs.map +2 -2
  241. package/dist/scan/index.d.ts +2 -1
  242. package/dist/scan/index.d.ts.map +1 -1
  243. package/dist/scan/index.js +2 -1
  244. package/dist/scan/index.js.map +1 -1
  245. package/dist/scan/parse-sql-predicate.cjs +2 -2
  246. package/dist/scan/parse-sql-predicate.cjs.map +2 -2
  247. package/dist/scan/parse-sql-predicate.js +1 -1
  248. package/dist/scan/parse-sql-predicate.js.map +1 -1
  249. package/dist/scan/query-pushdown.cjs +6 -6
  250. package/dist/scan/query-pushdown.cjs.map +2 -2
  251. package/dist/scan/query-pushdown.d.ts +1 -1
  252. package/dist/scan/query-pushdown.d.ts.map +1 -1
  253. package/dist/scan/query-pushdown.js +3 -6
  254. package/dist/scan/query-pushdown.js.map +1 -1
  255. package/dist/scan/query-scales.cjs +195 -0
  256. package/dist/scan/query-scales.cjs.map +7 -0
  257. package/dist/scan/query-scales.d.ts +47 -0
  258. package/dist/scan/query-scales.d.ts.map +1 -0
  259. package/dist/scan/query-scales.js +201 -0
  260. package/dist/scan/query-scales.js.map +1 -0
  261. package/dist/scan/query.cjs +49 -45
  262. package/dist/scan/query.cjs.map +2 -2
  263. package/dist/scan/query.d.ts +7 -4
  264. package/dist/scan/query.d.ts.map +1 -1
  265. package/dist/scan/query.js +35 -52
  266. package/dist/scan/query.js.map +1 -1
  267. package/dist/scan/vector-table-scan-source.cjs +19 -13
  268. package/dist/scan/vector-table-scan-source.cjs.map +3 -3
  269. package/dist/scan/vector-table-scan-source.d.ts +3 -4
  270. package/dist/scan/vector-table-scan-source.d.ts.map +1 -1
  271. package/dist/scan/vector-table-scan-source.js +11 -12
  272. package/dist/scan/vector-table-scan-source.js.map +1 -1
  273. package/dist/schema/categories/category-mesh.d.ts +3 -10
  274. package/dist/schema/categories/category-mesh.d.ts.map +1 -1
  275. package/dist/schema/categories/category-mesh.js.map +1 -1
  276. package/dist/schema/categories/category-table.d.ts +2 -19
  277. package/dist/schema/categories/category-table.d.ts.map +1 -1
  278. package/dist/schema/geometry/arrow-binary-features.d.ts +1 -1
  279. package/dist/schema/geometry/arrow-binary-features.d.ts.map +1 -1
  280. package/dist/schema/geometry/geoarrow.d.ts +2 -2
  281. package/dist/schema/geometry/geoarrow.d.ts.map +1 -1
  282. package/dist/schema/index.cjs.map +1 -1
  283. package/dist/schema/index.d.ts +2 -2
  284. package/dist/schema/index.d.ts.map +1 -1
  285. package/dist/schema/index.js.map +1 -1
  286. package/dist/schema/types/batch.d.ts +0 -4
  287. package/dist/schema/types/batch.d.ts.map +1 -1
  288. package/dist/schema-utils/index.cjs +420 -503
  289. package/dist/schema-utils/index.cjs.map +3 -3
  290. package/dist/schema-utils/index.d.ts +4 -5
  291. package/dist/schema-utils/index.d.ts.map +1 -1
  292. package/dist/schema-utils/index.js +4 -5
  293. package/dist/schema-utils/index.js.map +1 -1
  294. package/dist/schema-utils/lib/arrow/arrow-metadata.d.ts +4 -5
  295. package/dist/schema-utils/lib/arrow/arrow-metadata.d.ts.map +1 -1
  296. package/dist/schema-utils/lib/arrow/arrow-metadata.js +21 -18
  297. package/dist/schema-utils/lib/arrow/arrow-metadata.js.map +1 -1
  298. package/dist/schema-utils/lib/mesh/convert-mesh-to-table.d.ts +6 -11
  299. package/dist/schema-utils/lib/mesh/convert-mesh-to-table.d.ts.map +1 -1
  300. package/dist/schema-utils/lib/mesh/convert-mesh-to-table.js +8 -21
  301. package/dist/schema-utils/lib/mesh/convert-mesh-to-table.js.map +1 -1
  302. package/dist/schema-utils/lib/mesh/convert-table-to-mesh.d.ts +4 -4
  303. package/dist/schema-utils/lib/mesh/convert-table-to-mesh.d.ts.map +1 -1
  304. package/dist/schema-utils/lib/mesh/convert-table-to-mesh.js +13 -15
  305. package/dist/schema-utils/lib/mesh/convert-table-to-mesh.js.map +1 -1
  306. package/dist/schema-utils/lib/mesh/point-cloud-tiler.d.ts +2 -2
  307. package/dist/schema-utils/lib/mesh/point-cloud-tiler.d.ts.map +1 -1
  308. package/dist/schema-utils/lib/mesh/point-cloud-tiler.js +1 -1
  309. package/dist/schema-utils/lib/mesh/point-cloud-tiler.js.map +1 -1
  310. package/dist/schema-utils/lib/schema/deduce-table-schema.d.ts +2 -1
  311. package/dist/schema-utils/lib/schema/deduce-table-schema.d.ts.map +1 -1
  312. package/dist/schema-utils/lib/schema/deduce-table-schema.js +3 -1
  313. package/dist/schema-utils/lib/schema/deduce-table-schema.js.map +1 -1
  314. package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.d.ts +6 -5
  315. package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.d.ts.map +1 -1
  316. package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.js +6 -5
  317. package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.js.map +1 -1
  318. package/dist/schema-utils/lib/table/batches/convert-batches.d.ts.map +1 -1
  319. package/dist/schema-utils/lib/table/batches/convert-batches.js +5 -8
  320. package/dist/schema-utils/lib/table/batches/convert-batches.js.map +1 -1
  321. package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.d.ts +1 -1
  322. package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.d.ts.map +1 -1
  323. package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.js +2 -6
  324. package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.js.map +1 -1
  325. package/dist/schema-utils/lib/table/batches/make-table-from-batches.d.ts +1 -1
  326. package/dist/schema-utils/lib/table/batches/make-table-from-batches.d.ts.map +1 -1
  327. package/dist/schema-utils/lib/table/batches/make-table-from-batches.js +4 -24
  328. package/dist/schema-utils/lib/table/batches/make-table-from-batches.js.map +1 -1
  329. package/dist/schema-utils/lib/table/tables/convert-arrow-table.d.ts +3 -6
  330. package/dist/schema-utils/lib/table/tables/convert-arrow-table.d.ts.map +1 -1
  331. package/dist/schema-utils/lib/table/tables/convert-arrow-table.js +8 -58
  332. package/dist/schema-utils/lib/table/tables/convert-arrow-table.js.map +1 -1
  333. package/dist/schema-utils/lib/table/tables/make-table.js +2 -2
  334. package/dist/schema-utils/lib/table/tables/make-table.js.map +1 -1
  335. package/dist/schema-utils/lib/table/tables/table-accessors.d.ts.map +1 -1
  336. package/dist/schema-utils/lib/table/tables/table-accessors.js +2 -16
  337. package/dist/schema-utils/lib/table/tables/table-accessors.js.map +1 -1
  338. package/dist/schema-utils/lib/table/tables/table-converter/table-converter.d.ts +2 -2
  339. package/dist/schema-utils/lib/table/tables/table-converter/table-converter.d.ts.map +1 -1
  340. package/dist/schema-utils/lib/table/tables/table-converter/table-converter.js +4 -4
  341. package/dist/schema-utils/lib/table/tables/table-converter/table-converter.js.map +1 -1
  342. package/dist/schema-utils/lib/table/tables/table-types.d.ts +1 -3
  343. package/dist/schema-utils/lib/table/tables/table-types.d.ts.map +1 -1
  344. package/dist/schema-utils/lib/table/tables/table-types.js +0 -4
  345. package/dist/schema-utils/lib/table/tables/table-types.js.map +1 -1
  346. package/dist/vector-table-scan-source.cjs +17 -11
  347. package/dist/vector-table-scan-source.cjs.map +2 -2
  348. package/dist/wkt/index.cjs.map +1 -1
  349. package/dist/wkt/index.d.ts.map +1 -1
  350. package/dist/wkt/index.js.map +1 -1
  351. package/dist/worker-utils/index.cjs +2 -2
  352. package/dist/worker-utils/lib/env-utils/version.js +1 -1
  353. package/dist/worker-utils/lib/npm-tag.d.ts.map +1 -1
  354. package/dist/worker-utils/lib/npm-tag.js.map +1 -1
  355. package/dist/worker-utils/null-worker-node.js.map +1 -1
  356. package/dist/worker-utils/null-worker.js.map +1 -1
  357. package/package.json +22 -8
  358. package/src/arrow-geometry/binary-features.ts +4 -1
  359. package/src/arrow-geometry/binary-geometry-to-wkb.ts +1 -1
  360. package/src/arrow-geometry/feature-collection-to-arrow.ts +5 -8
  361. package/src/arrow-geometry/feature-table.ts +8 -21
  362. package/src/arrow-geometry/geojson-table.ts +2 -2
  363. package/src/arrow-geometry/geometry-codecs.ts +2 -2
  364. package/src/arrow-geometry/geometry-to-wkt.ts +2 -2
  365. package/src/arrow-geometry/legacy-binary/convert-flat-geojson-to-binary-features.ts +3 -1
  366. package/src/arrow-geometry/wkb-arrow-utils.ts +8 -12
  367. package/src/arrow-geometry/wkb-builder.ts +2 -2
  368. package/src/arrow-geometry/wkb-statistics.ts +2 -2
  369. package/src/arrow-worker-transport.ts +22 -121
  370. package/src/geoarrow/binary-polygon-to-geoarrow.ts +2 -2
  371. package/src/geoarrow/clustering/cluster-source.ts +16 -23
  372. package/src/geoarrow/convert-table-to-geoarrow.ts +11 -23
  373. package/src/geoarrow/geoarrow-bounds.ts +3 -3
  374. package/src/geoarrow/geoarrow-capabilities.ts +1 -1
  375. package/src/geoarrow/geoarrow-converter/convert-geoarrow-geometry.ts +3 -7
  376. package/src/geoarrow/geoarrow-converter/convert-geoarrow.ts +2 -2
  377. package/src/geoarrow/geoarrow-converter/geoarrow-converter.ts +2 -4
  378. package/src/geoarrow/geoarrow-inspection.ts +2 -2
  379. package/src/geoarrow/geoarrow-stream.ts +15 -15
  380. package/src/geoarrow/get-geoarrow-vertex-count.ts +1 -1
  381. package/src/geoarrow/lib/feature-collection-converters/convert-arrow-binary-feature-collection.ts +3 -3
  382. package/src/geoarrow/lib/feature-collection-converters/convert-geometry-column-to-binary-feature-collection.ts +5 -2
  383. package/src/geoarrow/lib/geometry-converters/wkb/convert-wkb-to-binary-geometry.ts +1 -1
  384. package/src/geoarrow/lib/geometry-converters/wkb/helpers/parse-wkb-header.ts +2 -2
  385. package/src/geoarrow/lib/kernels/encode-geoarrow-box.ts +1 -1
  386. package/src/geoarrow/lib/table-converters/convert-geoarrow-table.ts +7 -5
  387. package/src/geoarrow/mesharrow/arrow-fixed-size-list-utils.ts +1 -1
  388. package/src/index.ts +1 -1
  389. package/src/lib/api/load.ts +2 -12
  390. package/src/lib/api/loader-options.ts +69 -0
  391. package/src/lib/api/parse-file.ts +2 -11
  392. package/src/lib/api/parse-in-batches.ts +8 -12
  393. package/src/lib/api/parse-sync.ts +3 -7
  394. package/src/lib/api/parse.ts +2 -6
  395. package/src/lib/loader-utils/native-arrow.ts +12 -38
  396. package/src/loader-utils/index.ts +0 -1
  397. package/src/loader-utils/lib/scan-utils/scan-query-metadata.ts +7 -6
  398. package/src/loader-utils/lib/scan-utils/table-scan-batch.ts +64 -41
  399. package/src/loader-utils/lib/sources/table-source-collection.ts +2 -1
  400. package/src/loader-utils/lib/sources/tile-grid.ts +34 -18
  401. package/src/loader-utils/lib/sources/vector-tile-source.ts +3 -9
  402. package/src/loader-utils/loader-types.ts +3 -3
  403. package/src/scan/arrow-execution/expressions.ts +7 -7
  404. package/src/scan/arrow-execution/filter-arrow-table.ts +1 -1
  405. package/src/scan/arrow-query-worker-entry.ts +8 -0
  406. package/src/scan/arrow-query-worker.ts +158 -0
  407. package/src/scan/federated-table-scan-source.ts +15 -18
  408. package/src/scan/index.ts +7 -1
  409. package/src/scan/parse-sql-predicate.ts +1 -1
  410. package/src/scan/query-pushdown.ts +7 -7
  411. package/src/scan/query-scales.ts +299 -0
  412. package/src/scan/query.ts +68 -71
  413. package/src/scan/vector-table-scan-source.ts +16 -21
  414. package/src/schema/categories/category-mesh.ts +3 -11
  415. package/src/schema/categories/category-table.ts +2 -28
  416. package/src/schema/geometry/arrow-binary-features.ts +1 -1
  417. package/src/schema/geometry/geoarrow.ts +2 -2
  418. package/src/schema/index.ts +1 -3
  419. package/src/schema/types/batch.ts +0 -5
  420. package/src/schema-utils/index.ts +5 -11
  421. package/src/schema-utils/lib/arrow/arrow-metadata.ts +33 -30
  422. package/src/schema-utils/lib/mesh/convert-mesh-to-table.ts +12 -38
  423. package/src/schema-utils/lib/mesh/convert-table-to-mesh.ts +15 -18
  424. package/src/schema-utils/lib/mesh/point-cloud-tiler.ts +4 -13
  425. package/src/schema-utils/lib/schema/deduce-table-schema.ts +4 -2
  426. package/src/schema-utils/lib/table/arrow-api/arrow-like-table.ts +10 -9
  427. package/src/schema-utils/lib/table/batches/convert-batches.ts +5 -8
  428. package/src/schema-utils/lib/table/batches/make-arrow-batch-iterator.ts +2 -6
  429. package/src/schema-utils/lib/table/batches/make-table-from-batches.ts +5 -27
  430. package/src/schema-utils/lib/table/tables/convert-arrow-table.ts +11 -73
  431. package/src/schema-utils/lib/table/tables/make-table.ts +2 -2
  432. package/src/schema-utils/lib/table/tables/table-accessors.ts +2 -22
  433. package/src/schema-utils/lib/table/tables/table-converter/table-converter.ts +6 -6
  434. package/src/schema-utils/lib/table/tables/table-types.ts +1 -7
  435. package/src/wkt/index.ts +1 -1
  436. package/src/worker-utils/lib/npm-tag.ts +1 -1
  437. package/dist/schema-utils/lib/table/tables/convert-arrow-table-wrapper.d.ts +0 -27
  438. package/dist/schema-utils/lib/table/tables/convert-arrow-table-wrapper.d.ts.map +0 -1
  439. package/dist/schema-utils/lib/table/tables/convert-arrow-table-wrapper.js +0 -23
  440. package/dist/schema-utils/lib/table/tables/convert-arrow-table-wrapper.js.map +0 -1
  441. package/src/schema-utils/lib/table/tables/convert-arrow-table-wrapper.ts +0 -54
@@ -184,7 +184,6 @@ __export(index_exports, {
184
184
  log: () => log,
185
185
  makeLineIterator: () => makeLineIterator,
186
186
  makeNumberedLineIterator: () => makeNumberedLineIterator,
187
- makeTableScanBatch: () => makeTableScanBatch,
188
187
  makeTextDecoderIterator: () => makeTextDecoderIterator,
189
188
  makeTextEncoderIterator: () => makeTextEncoderIterator,
190
189
  mergeOptions: () => mergeOptions,
@@ -293,7 +292,7 @@ var nodeVersion = matches && parseFloat(matches[1]) || 0;
293
292
 
294
293
  // dist/loader-utils/lib/log-utils/log.js
295
294
  var import_log = require("probe.gl/log");
296
- var VERSION = true ? "5.0.0-beta.10" : "latest";
295
+ var VERSION = true ? "5.0.0-beta.12" : "latest";
297
296
  var version = VERSION[0] >= "0" && VERSION[0] <= "9" ? `v${VERSION}` : "";
298
297
  function createLog() {
299
298
  const log3 = new import_log.Log({ id: "loaders.gl" });
@@ -9210,7 +9209,7 @@ var CachedUriResolver = class {
9210
9209
  };
9211
9210
 
9212
9211
  // dist/loader-utils/json-loader.js
9213
- var VERSION3 = true ? "5.0.0-beta.10" : "latest";
9212
+ var VERSION3 = true ? "5.0.0-beta.12" : "latest";
9214
9213
  var JSONLoader = {
9215
9214
  dataType: null,
9216
9215
  batchType: null,
@@ -10952,6 +10951,7 @@ function createScanQueryMetadata(options) {
10952
10951
  columns: Object.freeze(columns),
10953
10952
  capabilities: queryCapabilities,
10954
10953
  queryCapabilities,
10954
+ ...options.hasDefaultRowWindow ? { hasDefaultRowWindow: true } : {},
10955
10955
  spatial: options.spatial ? Object.freeze({
10956
10956
  ...options.spatial,
10957
10957
  bounds: options.spatial.bounds ? Object.freeze({
@@ -11045,9 +11045,6 @@ function validateTableQueryOffset(offset) {
11045
11045
  }
11046
11046
 
11047
11047
  // dist/loader-utils/lib/scan-utils/table-scan-batch.js
11048
- function makeTableScanBatch(table) {
11049
- return { ...table, batchType: "data", length: table.data.numRows };
11050
- }
11051
11048
  async function* executeTableScanBatches(readBatches, options = {}, operators = {}) {
11052
11049
  var _a, _b, _c, _d, _e;
11053
11050
  validateTableQueryLimit(options.limit);
@@ -11079,23 +11076,28 @@ async function* executeTableScanBatches(readBatches, options = {}, operators = {
11079
11076
  }
11080
11077
  (_b = options.signal) == null ? void 0 : _b.throwIfAborted();
11081
11078
  batchesRead++;
11082
- rowsRead += batch.length;
11083
- const filteredBatch = await (operators.filter || filterTableBatch)(batch, options.predicate, options.signal);
11079
+ const rowCount = getScanBatchRowCount(batch);
11080
+ rowsRead += rowCount;
11081
+ if (options.predicate && !operators.filter && !("shape" in batch)) {
11082
+ throw new Error("Native Arrow scans require a filter kernel for residual predicates.");
11083
+ }
11084
+ const filteredBatch = operators.filter ? await operators.filter(batch, options.predicate, options.signal) : "shape" in batch ? filterTableBatch(batch, options.predicate) : batch;
11084
11085
  (_c = options.signal) == null ? void 0 : _c.throwIfAborted();
11086
+ const filteredRowCount = getScanBatchRowCount(filteredBatch);
11085
11087
  if (options.predicate) {
11086
- rowsTested += batch.length;
11087
- rowsRetained += filteredBatch.length;
11088
+ rowsTested += rowCount;
11089
+ rowsRetained += filteredRowCount;
11088
11090
  }
11089
- if (skip >= filteredBatch.length && (skip > 0 || options.skipEmptyBatches)) {
11090
- skip -= filteredBatch.length;
11091
+ if (skip >= filteredRowCount && (skip > 0 || options.skipEmptyBatches)) {
11092
+ skip -= filteredRowCount;
11091
11093
  continue;
11092
11094
  }
11093
- const end = Math.min(filteredBatch.length, skip + remaining);
11094
- const window2 = skip || end < filteredBatch.length ? sliceTableBatch(filteredBatch, skip, end) : filteredBatch;
11095
+ const end = Math.min(filteredRowCount, skip + remaining);
11096
+ const window2 = skip || end < filteredRowCount ? "shape" in filteredBatch ? sliceTableBatch(filteredBatch, skip, end) : filteredBatch.slice(skip, end) : filteredBatch;
11095
11097
  skip = 0;
11096
- const output = (operators.project || projectTableBatch)(window2, options.columns);
11097
- remaining -= window2.length;
11098
- rowsReturned += output.length;
11098
+ const output = operators.project ? operators.project(window2, options.columns) : projectTableBatch(window2, options.columns);
11099
+ remaining -= getScanBatchRowCount(window2);
11100
+ rowsReturned += getScanBatchRowCount(output);
11099
11101
  if (remaining === 0)
11100
11102
  earlyTerminationReason = "limit";
11101
11103
  yield output;
@@ -11132,8 +11134,11 @@ async function* executeTableScanBatches(readBatches, options = {}, operators = {
11132
11134
  }));
11133
11135
  }
11134
11136
  }
11137
+ function getScanBatchRowCount(batch) {
11138
+ return "shape" in batch ? batch.length : batch.numRows;
11139
+ }
11135
11140
  function truncateTableBatch(batch, length) {
11136
- return sliceTableBatch(batch, 0, length);
11141
+ return "shape" in batch ? sliceTableBatch(batch, 0, length) : batch.slice(0, length);
11137
11142
  }
11138
11143
  function sliceTableBatch(batch, start, end) {
11139
11144
  const length = end - start;
@@ -11150,13 +11155,15 @@ function sliceTableBatch(batch, start, end) {
11150
11155
  length
11151
11156
  };
11152
11157
  }
11153
- if (batch.shape === "arrow-table")
11154
- return { ...batch, data: batch.data.slice(start, end), length };
11155
11158
  return { ...batch, features: batch.features.slice(start, end), length };
11156
11159
  }
11157
11160
  function projectTableBatch(batch, columns) {
11158
11161
  if (columns === void 0)
11159
11162
  return batch;
11163
+ if (!("shape" in batch)) {
11164
+ const indices = columns.map((column) => batch.schema.fields.findIndex((field) => field.name === column)).filter((index) => index >= 0);
11165
+ return batch.selectAt(indices);
11166
+ }
11160
11167
  const schema = projectTableSchema(batch, columns);
11161
11168
  if (batch.shape === "object-row-table") {
11162
11169
  return {
@@ -11172,8 +11179,6 @@ function projectTableBatch(batch, columns) {
11172
11179
  data: Object.fromEntries(columns.map((column) => [column, batch.data[column]]))
11173
11180
  };
11174
11181
  }
11175
- if (batch.shape === "arrow-table")
11176
- return { ...batch, schema, data: batch.data.select([...columns]) };
11177
11182
  return batch;
11178
11183
  }
11179
11184
  function projectTableSchema(batch, columns) {
@@ -11652,6 +11657,16 @@ function getTileGridValidation(grid) {
11652
11657
  message: error instanceof Error ? error.message : "Invalid tile grid limits."
11653
11658
  });
11654
11659
  }
11660
+ if (matrixSet && !issues.length) {
11661
+ try {
11662
+ (0, import_geospatial.validateTileMatrixSet)(matrixSet, grid.limits);
11663
+ } catch (error) {
11664
+ issues.push({
11665
+ code: "invalid-matrix",
11666
+ message: error instanceof Error ? error.message : "Invalid tile matrix set."
11667
+ });
11668
+ }
11669
+ }
11655
11670
  const invalid = issues.some((issue) => issue.code !== "missing-crs" && issue.code !== "missing-geometry");
11656
11671
  return { status: invalid ? "invalid" : issues.length ? "partial" : "complete", issues };
11657
11672
  }
@@ -11670,12 +11685,17 @@ function validateTileGridLimits(grid) {
11670
11685
  throw new RangeError("Tile matrix limits require an array.");
11671
11686
  const identifiers = /* @__PURE__ */ new Set();
11672
11687
  const matrices = ((_a = grid.tileMatrixSet) == null ? void 0 : _a.matrices) ?? grid.matrices;
11688
+ const matrixById = Array.isArray(matrices) ? new Map(matrices.map((matrix) => [matrix == null ? void 0 : matrix.id, matrix])) : void 0;
11673
11689
  for (const limit of grid.limits) {
11674
- if (!limit || typeof limit.tileMatrix !== "string" || !limit.tileMatrix || identifiers.has(limit.tileMatrix) || ![limit.minTileColumn, limit.maxTileColumn, limit.minTileRow, limit.maxTileRow].every((value) => Number.isSafeInteger(value) && value >= 0) || limit.minTileColumn > limit.maxTileColumn || limit.minTileRow > limit.maxTileRow)
11675
- throw new RangeError("Invalid tile matrix limits.");
11690
+ if (!limit || typeof limit.tileMatrix !== "string" || !limit.tileMatrix || identifiers.has(limit.tileMatrix))
11691
+ throw new RangeError("Tile matrix limits require unique nonempty matrix identifiers.");
11676
11692
  identifiers.add(limit.tileMatrix);
11677
- const matrix = matrices == null ? void 0 : matrices.find((candidate) => candidate.id === limit.tileMatrix);
11678
- if (matrices && !matrix)
11693
+ if (![limit.minTileColumn, limit.maxTileColumn, limit.minTileRow, limit.maxTileRow].every((value) => Number.isSafeInteger(value) && value >= 0))
11694
+ throw new RangeError("Tile matrix limits require nonnegative safe integers.");
11695
+ if (limit.minTileColumn > limit.maxTileColumn || limit.minTileRow > limit.maxTileRow)
11696
+ throw new RangeError("Tile matrix limits have reversed bounds.");
11697
+ const matrix = matrixById == null ? void 0 : matrixById.get(limit.tileMatrix);
11698
+ if (matrixById && !matrix)
11679
11699
  throw new RangeError("Tile matrix limits reference an unknown matrix.");
11680
11700
  if ((matrix == null ? void 0 : matrix.matrixSize) && (limit.maxTileColumn >= matrix.matrixSize[0] || limit.maxTileRow >= matrix.matrixSize[1]))
11681
11701
  throw new RangeError("Tile matrix limits exceed matrix dimensions.");
@@ -11699,11 +11719,8 @@ function resolveTileGridTile(grid, parameters) {
11699
11719
  if ((matrix == null ? void 0 : matrix.matrixSize) && (parameters.x >= matrix.matrixSize[0] || parameters.y >= matrix.matrixSize[1]))
11700
11720
  return null;
11701
11721
  if (matrix && grid.tileMatrixSet) {
11702
- const geometry = matrix;
11703
- const ranges = (0, import_geospatial.getTileRanges)(geometry, (0, import_geospatial.getTileBounds)(geometry, parameters.x, parameters.y), limits);
11704
- if (!ranges.length)
11705
- return null;
11706
- return { ...parameters, x: ranges[0].minTileColumn, tileMatrix };
11722
+ const index = (0, import_geospatial.resolveTileIndex)(matrix, parameters.x, parameters.y, limits);
11723
+ return index ? { ...parameters, x: index[0], tileMatrix } : null;
11707
11724
  }
11708
11725
  if ((_c = matrix == null ? void 0 : matrix.variableMatrixWidths) == null ? void 0 : _c.length)
11709
11726
  throw new RangeError("Coalesced tile requests require complete geometry.");