@loaders.gl/schema 3.1.0 → 3.1.4

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.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAuBA;;AAEA;;AACA;;AAEA;;AAYA;;AACA;;AACA;;AAmCA;;AA0CA;;AACA;;AACA;;AAEA","sourcesContent":["// COMMON CATEGORY\nexport type {TypedArray, NumberArray, AnyArray} from './types';\n\nexport type {Batch} from './category/common';\n\n// TABLE CATEGORY TYPES\n\nexport type {\n Table,\n ArrayRowTable,\n ObjectRowTable,\n ColumnarTable,\n ArrowTable\n} from './category/table/table-types';\nexport type {\n TableBatch,\n RowArrayTableBatch,\n RowObjectTableBatch,\n ColumnarTableBatch,\n ArrowTableBatch\n} from './category/table/table-types';\n\n// TABLE CATEGORY UTILS\nexport {default as TableBatchBuilder} from './lib/batches/table-batch-builder';\nexport type {TableBatchAggregator} from './lib/batches/table-batch-aggregator';\nexport {default as RowTableBatchAggregator} from './lib/batches/row-table-batch-aggregator';\nexport {default as ColumnarTableBatchAggregator} from './lib/batches/columnar-table-batch-aggregator';\n\nexport {convertToObjectRow, convertToArrayRow} from './lib/utils/row-utils';\n\n// MESH CATEGORY\nexport type {\n MeshTable,\n MeshArrowTable,\n Mesh,\n MeshGeometry,\n MeshAttribute,\n MeshAttributes\n} from './category/mesh/mesh-types';\n\nexport {getMeshSize, getMeshBoundingBox} from './category/mesh/mesh-utils';\nexport {convertMesh} from './category/mesh/convert-mesh';\nexport {\n deduceMeshSchema,\n deduceMeshField,\n makeMeshAttributeMetadata\n} from './category/mesh/deduce-mesh-schema';\n\n// TYPES\n// GIS CATEGORY - GEOJSON\nexport type {GeoJSON, Feature, Geometry, Position, GeoJsonProperties} from './category/gis';\nexport type {\n Point,\n MultiPoint,\n LineString,\n MultiLineString,\n Polygon,\n MultiPolygon\n} from './category/gis';\n\n// GIS CATEGORY - BINARY\nexport type {\n BinaryGeometryType,\n BinaryGeometry,\n BinaryPointGeometry,\n BinaryLineGeometry,\n BinaryPolygonGeometry,\n BinaryAttribute\n} from './category/gis';\nexport type {\n BinaryFeatures,\n BinaryPointFeatures,\n BinaryLineFeatures,\n BinaryPolygonFeatures\n} from './category/gis';\n\n// SCHEMA\nexport {\n Schema,\n Field,\n DataType,\n Null,\n Binary,\n Bool,\n Int,\n Int8,\n Int16,\n Int32,\n Int64,\n Uint8,\n Uint16,\n Uint32,\n Uint64,\n Float,\n Float16,\n Float32,\n Float64,\n Utf8,\n Date,\n DateDay,\n DateMillisecond,\n Time,\n TimeMillisecond,\n TimeSecond,\n Timestamp,\n TimestampSecond,\n TimestampMillisecond,\n TimestampMicrosecond,\n TimestampNanosecond,\n Interval,\n IntervalDayTime,\n IntervalYearMonth,\n FixedSizeList,\n Struct\n} from './lib/schema/schema';\n\n// EXPERIMENTAL APIs\n\n// SCHEMA UTILS\nexport {deduceTypeFromColumn, deduceTypeFromValue} from './lib/schema-utils/deduce-column-type';\nexport {getTypeInfo} from './lib/arrow/get-type-info';\nexport {getArrowTypeFromTypedArray} from './lib/arrow/arrow-like-type-utils';\n\nexport {default as AsyncQueue} from './lib/utils/async-queue';\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAuBA;;AAEA;;AACA;;AAEA;;AAYA;;AACA;;AACA;;AAiDA;;AA0CA;;AACA;;AACA;;AAEA","sourcesContent":["// COMMON CATEGORY\nexport type {TypedArray, NumberArray, AnyArray} from './types';\n\nexport type {Batch} from './category/common';\n\n// TABLE CATEGORY TYPES\n\nexport type {\n Table,\n ArrayRowTable,\n ObjectRowTable,\n ColumnarTable,\n ArrowTable\n} from './category/table/table-types';\nexport type {\n TableBatch,\n RowArrayTableBatch,\n RowObjectTableBatch,\n ColumnarTableBatch,\n ArrowTableBatch\n} from './category/table/table-types';\n\n// TABLE CATEGORY UTILS\nexport {default as TableBatchBuilder} from './lib/batches/table-batch-builder';\nexport type {TableBatchAggregator} from './lib/batches/table-batch-aggregator';\nexport {default as RowTableBatchAggregator} from './lib/batches/row-table-batch-aggregator';\nexport {default as ColumnarTableBatchAggregator} from './lib/batches/columnar-table-batch-aggregator';\n\nexport {convertToObjectRow, convertToArrayRow} from './lib/utils/row-utils';\n\n// MESH CATEGORY\nexport type {\n MeshTable,\n MeshArrowTable,\n Mesh,\n MeshGeometry,\n MeshAttribute,\n MeshAttributes\n} from './category/mesh/mesh-types';\n\nexport {getMeshSize, getMeshBoundingBox} from './category/mesh/mesh-utils';\nexport {convertMesh} from './category/mesh/convert-mesh';\nexport {\n deduceMeshSchema,\n deduceMeshField,\n makeMeshAttributeMetadata\n} from './category/mesh/deduce-mesh-schema';\n\n// TYPES\n// GIS CATEGORY - GEOJSON\nexport type {GeoJSON, Feature, Geometry, Position, GeoJsonProperties} from './category/gis';\nexport type {\n Point,\n MultiPoint,\n LineString,\n MultiLineString,\n Polygon,\n MultiPolygon,\n GeometryCollection\n} from './category/gis';\n\nexport type {GeojsonGeometryInfo} from './category/gis';\n\n// GIS CATEGORY - FLAT GEOJSON\nexport type {\n FlatFeature,\n FlatIndexedGeometry,\n FlatGeometry,\n FlatGeometryType,\n FlatPoint,\n FlatLineString,\n FlatPolygon\n} from './category/gis';\n\n// GIS CATEGORY - BINARY\nexport type {\n BinaryGeometryType,\n BinaryGeometry,\n BinaryPointGeometry,\n BinaryLineGeometry,\n BinaryPolygonGeometry,\n BinaryAttribute\n} from './category/gis';\nexport type {\n BinaryFeatures,\n BinaryPointFeatures,\n BinaryLineFeatures,\n BinaryPolygonFeatures\n} from './category/gis';\n\n// SCHEMA\nexport {\n Schema,\n Field,\n DataType,\n Null,\n Binary,\n Bool,\n Int,\n Int8,\n Int16,\n Int32,\n Int64,\n Uint8,\n Uint16,\n Uint32,\n Uint64,\n Float,\n Float16,\n Float32,\n Float64,\n Utf8,\n Date,\n DateDay,\n DateMillisecond,\n Time,\n TimeMillisecond,\n TimeSecond,\n Timestamp,\n TimestampSecond,\n TimestampMillisecond,\n TimestampMicrosecond,\n TimestampNanosecond,\n Interval,\n IntervalDayTime,\n IntervalYearMonth,\n FixedSizeList,\n Struct\n} from './lib/schema/schema';\n\n// EXPERIMENTAL APIs\n\n// SCHEMA UTILS\nexport {deduceTypeFromColumn, deduceTypeFromValue} from './lib/schema-utils/deduce-column-type';\nexport {getTypeInfo} from './lib/arrow/get-type-info';\nexport {getArrowTypeFromTypedArray} from './lib/arrow/arrow-like-type-utils';\n\nexport {default as AsyncQueue} from './lib/utils/async-queue';\n"],"file":"index.js"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.ts"],"names":["default","TableBatchBuilder","RowTableBatchAggregator","ColumnarTableBatchAggregator","convertToObjectRow","convertToArrayRow","getMeshSize","getMeshBoundingBox","convertMesh","deduceMeshSchema","deduceMeshField","makeMeshAttributeMetadata","Schema","Field","DataType","Null","Binary","Bool","Int","Int8","Int16","Int32","Int64","Uint8","Uint16","Uint32","Uint64","Float","Float16","Float32","Float64","Utf8","Date","DateDay","DateMillisecond","Time","TimeMillisecond","TimeSecond","Timestamp","TimestampSecond","TimestampMillisecond","TimestampMicrosecond","TimestampNanosecond","Interval","IntervalDayTime","IntervalYearMonth","FixedSizeList","Struct","deduceTypeFromColumn","deduceTypeFromValue","getTypeInfo","getArrowTypeFromTypedArray","AsyncQueue"],"mappings":"AAuBA,SAAQA,OAAO,IAAIC,iBAAnB,QAA2C,mCAA3C;AAEA,SAAQD,OAAO,IAAIE,uBAAnB,QAAiD,0CAAjD;AACA,SAAQF,OAAO,IAAIG,4BAAnB,QAAsD,+CAAtD;AAEA,SAAQC,kBAAR,EAA4BC,iBAA5B,QAAoD,uBAApD;AAYA,SAAQC,WAAR,EAAqBC,kBAArB,QAA8C,4BAA9C;AACA,SAAQC,WAAR,QAA0B,8BAA1B;AACA,SACEC,gBADF,EAEEC,eAFF,EAGEC,yBAHF,QAIO,oCAJP;AAmCA,SACEC,MADF,EAEEC,KAFF,EAGEC,QAHF,EAIEC,IAJF,EAKEC,MALF,EAMEC,IANF,EAOEC,GAPF,EAQEC,IARF,EASEC,KATF,EAUEC,KAVF,EAWEC,KAXF,EAYEC,KAZF,EAaEC,MAbF,EAcEC,MAdF,EAeEC,MAfF,EAgBEC,KAhBF,EAiBEC,OAjBF,EAkBEC,OAlBF,EAmBEC,OAnBF,EAoBEC,IApBF,EAqBEC,IArBF,EAsBEC,OAtBF,EAuBEC,eAvBF,EAwBEC,IAxBF,EAyBEC,eAzBF,EA0BEC,UA1BF,EA2BEC,SA3BF,EA4BEC,eA5BF,EA6BEC,oBA7BF,EA8BEC,oBA9BF,EA+BEC,mBA/BF,EAgCEC,QAhCF,EAiCEC,eAjCF,EAkCEC,iBAlCF,EAmCEC,aAnCF,EAoCEC,MApCF,QAqCO,qBArCP;AA0CA,SAAQC,oBAAR,EAA8BC,mBAA9B,QAAwD,uCAAxD;AACA,SAAQC,WAAR,QAA0B,2BAA1B;AACA,SAAQC,0BAAR,QAAyC,mCAAzC;AAEA,SAAQnD,OAAO,IAAIoD,UAAnB,QAAoC,yBAApC","sourcesContent":["// COMMON CATEGORY\nexport type {TypedArray, NumberArray, AnyArray} from './types';\n\nexport type {Batch} from './category/common';\n\n// TABLE CATEGORY TYPES\n\nexport type {\n Table,\n ArrayRowTable,\n ObjectRowTable,\n ColumnarTable,\n ArrowTable\n} from './category/table/table-types';\nexport type {\n TableBatch,\n RowArrayTableBatch,\n RowObjectTableBatch,\n ColumnarTableBatch,\n ArrowTableBatch\n} from './category/table/table-types';\n\n// TABLE CATEGORY UTILS\nexport {default as TableBatchBuilder} from './lib/batches/table-batch-builder';\nexport type {TableBatchAggregator} from './lib/batches/table-batch-aggregator';\nexport {default as RowTableBatchAggregator} from './lib/batches/row-table-batch-aggregator';\nexport {default as ColumnarTableBatchAggregator} from './lib/batches/columnar-table-batch-aggregator';\n\nexport {convertToObjectRow, convertToArrayRow} from './lib/utils/row-utils';\n\n// MESH CATEGORY\nexport type {\n MeshTable,\n MeshArrowTable,\n Mesh,\n MeshGeometry,\n MeshAttribute,\n MeshAttributes\n} from './category/mesh/mesh-types';\n\nexport {getMeshSize, getMeshBoundingBox} from './category/mesh/mesh-utils';\nexport {convertMesh} from './category/mesh/convert-mesh';\nexport {\n deduceMeshSchema,\n deduceMeshField,\n makeMeshAttributeMetadata\n} from './category/mesh/deduce-mesh-schema';\n\n// TYPES\n// GIS CATEGORY - GEOJSON\nexport type {GeoJSON, Feature, Geometry, Position, GeoJsonProperties} from './category/gis';\nexport type {\n Point,\n MultiPoint,\n LineString,\n MultiLineString,\n Polygon,\n MultiPolygon\n} from './category/gis';\n\n// GIS CATEGORY - BINARY\nexport type {\n BinaryGeometryType,\n BinaryGeometry,\n BinaryPointGeometry,\n BinaryLineGeometry,\n BinaryPolygonGeometry,\n BinaryAttribute\n} from './category/gis';\nexport type {\n BinaryFeatures,\n BinaryPointFeatures,\n BinaryLineFeatures,\n BinaryPolygonFeatures\n} from './category/gis';\n\n// SCHEMA\nexport {\n Schema,\n Field,\n DataType,\n Null,\n Binary,\n Bool,\n Int,\n Int8,\n Int16,\n Int32,\n Int64,\n Uint8,\n Uint16,\n Uint32,\n Uint64,\n Float,\n Float16,\n Float32,\n Float64,\n Utf8,\n Date,\n DateDay,\n DateMillisecond,\n Time,\n TimeMillisecond,\n TimeSecond,\n Timestamp,\n TimestampSecond,\n TimestampMillisecond,\n TimestampMicrosecond,\n TimestampNanosecond,\n Interval,\n IntervalDayTime,\n IntervalYearMonth,\n FixedSizeList,\n Struct\n} from './lib/schema/schema';\n\n// EXPERIMENTAL APIs\n\n// SCHEMA UTILS\nexport {deduceTypeFromColumn, deduceTypeFromValue} from './lib/schema-utils/deduce-column-type';\nexport {getTypeInfo} from './lib/arrow/get-type-info';\nexport {getArrowTypeFromTypedArray} from './lib/arrow/arrow-like-type-utils';\n\nexport {default as AsyncQueue} from './lib/utils/async-queue';\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../src/index.ts"],"names":["default","TableBatchBuilder","RowTableBatchAggregator","ColumnarTableBatchAggregator","convertToObjectRow","convertToArrayRow","getMeshSize","getMeshBoundingBox","convertMesh","deduceMeshSchema","deduceMeshField","makeMeshAttributeMetadata","Schema","Field","DataType","Null","Binary","Bool","Int","Int8","Int16","Int32","Int64","Uint8","Uint16","Uint32","Uint64","Float","Float16","Float32","Float64","Utf8","Date","DateDay","DateMillisecond","Time","TimeMillisecond","TimeSecond","Timestamp","TimestampSecond","TimestampMillisecond","TimestampMicrosecond","TimestampNanosecond","Interval","IntervalDayTime","IntervalYearMonth","FixedSizeList","Struct","deduceTypeFromColumn","deduceTypeFromValue","getTypeInfo","getArrowTypeFromTypedArray","AsyncQueue"],"mappings":"AAuBA,SAAQA,OAAO,IAAIC,iBAAnB,QAA2C,mCAA3C;AAEA,SAAQD,OAAO,IAAIE,uBAAnB,QAAiD,0CAAjD;AACA,SAAQF,OAAO,IAAIG,4BAAnB,QAAsD,+CAAtD;AAEA,SAAQC,kBAAR,EAA4BC,iBAA5B,QAAoD,uBAApD;AAYA,SAAQC,WAAR,EAAqBC,kBAArB,QAA8C,4BAA9C;AACA,SAAQC,WAAR,QAA0B,8BAA1B;AACA,SACEC,gBADF,EAEEC,eAFF,EAGEC,yBAHF,QAIO,oCAJP;AAiDA,SACEC,MADF,EAEEC,KAFF,EAGEC,QAHF,EAIEC,IAJF,EAKEC,MALF,EAMEC,IANF,EAOEC,GAPF,EAQEC,IARF,EASEC,KATF,EAUEC,KAVF,EAWEC,KAXF,EAYEC,KAZF,EAaEC,MAbF,EAcEC,MAdF,EAeEC,MAfF,EAgBEC,KAhBF,EAiBEC,OAjBF,EAkBEC,OAlBF,EAmBEC,OAnBF,EAoBEC,IApBF,EAqBEC,IArBF,EAsBEC,OAtBF,EAuBEC,eAvBF,EAwBEC,IAxBF,EAyBEC,eAzBF,EA0BEC,UA1BF,EA2BEC,SA3BF,EA4BEC,eA5BF,EA6BEC,oBA7BF,EA8BEC,oBA9BF,EA+BEC,mBA/BF,EAgCEC,QAhCF,EAiCEC,eAjCF,EAkCEC,iBAlCF,EAmCEC,aAnCF,EAoCEC,MApCF,QAqCO,qBArCP;AA0CA,SAAQC,oBAAR,EAA8BC,mBAA9B,QAAwD,uCAAxD;AACA,SAAQC,WAAR,QAA0B,2BAA1B;AACA,SAAQC,0BAAR,QAAyC,mCAAzC;AAEA,SAAQnD,OAAO,IAAIoD,UAAnB,QAAoC,yBAApC","sourcesContent":["// COMMON CATEGORY\nexport type {TypedArray, NumberArray, AnyArray} from './types';\n\nexport type {Batch} from './category/common';\n\n// TABLE CATEGORY TYPES\n\nexport type {\n Table,\n ArrayRowTable,\n ObjectRowTable,\n ColumnarTable,\n ArrowTable\n} from './category/table/table-types';\nexport type {\n TableBatch,\n RowArrayTableBatch,\n RowObjectTableBatch,\n ColumnarTableBatch,\n ArrowTableBatch\n} from './category/table/table-types';\n\n// TABLE CATEGORY UTILS\nexport {default as TableBatchBuilder} from './lib/batches/table-batch-builder';\nexport type {TableBatchAggregator} from './lib/batches/table-batch-aggregator';\nexport {default as RowTableBatchAggregator} from './lib/batches/row-table-batch-aggregator';\nexport {default as ColumnarTableBatchAggregator} from './lib/batches/columnar-table-batch-aggregator';\n\nexport {convertToObjectRow, convertToArrayRow} from './lib/utils/row-utils';\n\n// MESH CATEGORY\nexport type {\n MeshTable,\n MeshArrowTable,\n Mesh,\n MeshGeometry,\n MeshAttribute,\n MeshAttributes\n} from './category/mesh/mesh-types';\n\nexport {getMeshSize, getMeshBoundingBox} from './category/mesh/mesh-utils';\nexport {convertMesh} from './category/mesh/convert-mesh';\nexport {\n deduceMeshSchema,\n deduceMeshField,\n makeMeshAttributeMetadata\n} from './category/mesh/deduce-mesh-schema';\n\n// TYPES\n// GIS CATEGORY - GEOJSON\nexport type {GeoJSON, Feature, Geometry, Position, GeoJsonProperties} from './category/gis';\nexport type {\n Point,\n MultiPoint,\n LineString,\n MultiLineString,\n Polygon,\n MultiPolygon,\n GeometryCollection\n} from './category/gis';\n\nexport type {GeojsonGeometryInfo} from './category/gis';\n\n// GIS CATEGORY - FLAT GEOJSON\nexport type {\n FlatFeature,\n FlatIndexedGeometry,\n FlatGeometry,\n FlatGeometryType,\n FlatPoint,\n FlatLineString,\n FlatPolygon\n} from './category/gis';\n\n// GIS CATEGORY - BINARY\nexport type {\n BinaryGeometryType,\n BinaryGeometry,\n BinaryPointGeometry,\n BinaryLineGeometry,\n BinaryPolygonGeometry,\n BinaryAttribute\n} from './category/gis';\nexport type {\n BinaryFeatures,\n BinaryPointFeatures,\n BinaryLineFeatures,\n BinaryPolygonFeatures\n} from './category/gis';\n\n// SCHEMA\nexport {\n Schema,\n Field,\n DataType,\n Null,\n Binary,\n Bool,\n Int,\n Int8,\n Int16,\n Int32,\n Int64,\n Uint8,\n Uint16,\n Uint32,\n Uint64,\n Float,\n Float16,\n Float32,\n Float64,\n Utf8,\n Date,\n DateDay,\n DateMillisecond,\n Time,\n TimeMillisecond,\n TimeSecond,\n Timestamp,\n TimestampSecond,\n TimestampMillisecond,\n TimestampMicrosecond,\n TimestampNanosecond,\n Interval,\n IntervalDayTime,\n IntervalYearMonth,\n FixedSizeList,\n Struct\n} from './lib/schema/schema';\n\n// EXPERIMENTAL APIs\n\n// SCHEMA UTILS\nexport {deduceTypeFromColumn, deduceTypeFromValue} from './lib/schema-utils/deduce-column-type';\nexport {getTypeInfo} from './lib/arrow/get-type-info';\nexport {getArrowTypeFromTypedArray} from './lib/arrow/arrow-like-type-utils';\n\nexport {default as AsyncQueue} from './lib/utils/async-queue';\n"],"file":"index.js"}
package/dist/index.d.ts CHANGED
@@ -12,7 +12,9 @@ export { getMeshSize, getMeshBoundingBox } from './category/mesh/mesh-utils';
12
12
  export { convertMesh } from './category/mesh/convert-mesh';
13
13
  export { deduceMeshSchema, deduceMeshField, makeMeshAttributeMetadata } from './category/mesh/deduce-mesh-schema';
14
14
  export type { GeoJSON, Feature, Geometry, Position, GeoJsonProperties } from './category/gis';
15
- export type { Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon } from './category/gis';
15
+ export type { Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection } from './category/gis';
16
+ export type { GeojsonGeometryInfo } from './category/gis';
17
+ export type { FlatFeature, FlatIndexedGeometry, FlatGeometry, FlatGeometryType, FlatPoint, FlatLineString, FlatPolygon } from './category/gis';
16
18
  export type { BinaryGeometryType, BinaryGeometry, BinaryPointGeometry, BinaryLineGeometry, BinaryPolygonGeometry, BinaryAttribute } from './category/gis';
17
19
  export type { BinaryFeatures, BinaryPointFeatures, BinaryLineFeatures, BinaryPolygonFeatures } from './category/gis';
18
20
  export { Schema, Field, DataType, Null, Binary, Bool, Int, Int8, Int16, Int32, Int64, Uint8, Uint16, Uint32, Uint64, Float, Float16, Float32, Float64, Utf8, Date, DateDay, DateMillisecond, Time, TimeMillisecond, TimeSecond, Timestamp, TimestampSecond, TimestampMillisecond, TimestampMicrosecond, TimestampNanosecond, Interval, IntervalDayTime, IntervalYearMonth, FixedSizeList, Struct } from './lib/schema/schema';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,YAAY,EAAC,UAAU,EAAE,WAAW,EAAE,QAAQ,EAAC,MAAM,SAAS,CAAC;AAE/D,YAAY,EAAC,KAAK,EAAC,MAAM,mBAAmB,CAAC;AAI7C,YAAY,EACV,KAAK,EACL,aAAa,EACb,cAAc,EACd,aAAa,EACb,UAAU,EACX,MAAM,8BAA8B,CAAC;AACtC,YAAY,EACV,UAAU,EACV,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EAChB,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAC,OAAO,IAAI,iBAAiB,EAAC,MAAM,mCAAmC,CAAC;AAC/E,YAAY,EAAC,oBAAoB,EAAC,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAC,OAAO,IAAI,uBAAuB,EAAC,MAAM,0CAA0C,CAAC;AAC5F,OAAO,EAAC,OAAO,IAAI,4BAA4B,EAAC,MAAM,+CAA+C,CAAC;AAEtG,OAAO,EAAC,kBAAkB,EAAE,iBAAiB,EAAC,MAAM,uBAAuB,CAAC;AAG5E,YAAY,EACV,SAAS,EACT,cAAc,EACd,IAAI,EACJ,YAAY,EACZ,aAAa,EACb,cAAc,EACf,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EAAC,WAAW,EAAE,kBAAkB,EAAC,MAAM,4BAA4B,CAAC;AAC3E,OAAO,EAAC,WAAW,EAAC,MAAM,8BAA8B,CAAC;AACzD,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,yBAAyB,EAC1B,MAAM,oCAAoC,CAAC;AAI5C,YAAY,EAAC,OAAO,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W,EACZ,MAAM,gBAAgB,CAAC;AAGxB,YAAY,EACV,kBAAkB,EAClB,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,qBAAqB,EACrB,eAAe,EAChB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,MAAM,EACN,KAAK,EACL,QAAQ,EACR,IAAI,EACJ,MAAM,EACN,IAAI,EACJ,GAAG,EACH,IAAI,EACJ,KAAK,EACL,KAAK,EACL,KAAK,EACL,KAAK,EACL,MAAM,EACN,MAAM,EACN,MAAM,EACN,KAAK,EACL,OAAO,EACP,OAAO,EACP,OAAO,EACP,IAAI,EACJ,IAAI,EACJ,OAAO,EACP,eAAe,EACf,IAAI,EACJ,eAAe,EACf,UAAU,EACV,SAAS,EACT,eAAe,EACf,oBAAoB,EACpB,oBAAoB,EACpB,mBAAmB,EACnB,QAAQ,EACR,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,MAAM,EACP,MAAM,qBAAqB,CAAC;AAK7B,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAC,MAAM,uCAAuC,CAAC;AAChG,OAAO,EAAC,WAAW,EAAC,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAC,0BAA0B,EAAC,MAAM,mCAAmC,CAAC;AAE7E,OAAO,EAAC,OAAO,IAAI,UAAU,EAAC,MAAM,yBAAyB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loaders.gl/schema",
3
- "version": "3.1.0",
3
+ "version": "3.1.4",
4
4
  "description": "Table format APIs for JSON, CSV, etc...",
5
5
  "license": "MIT",
6
6
  "publishConfig": {
@@ -29,10 +29,10 @@
29
29
  ],
30
30
  "scripts": {
31
31
  "pre-build": "npm run build-bundle",
32
- "build-bundle": "esbuild src/bundle.ts --bundle --outfile=dist/bundle.js"
32
+ "build-bundle": "esbuild src/bundle.ts --bundle --outfile=dist/dist.min.js"
33
33
  },
34
34
  "dependencies": {
35
35
  "@types/geojson": "^7946.0.7"
36
36
  },
37
- "gitHead": "b02a011b5a6d6aa6c5870819045c70db168cb930"
37
+ "gitHead": "4d27d3ac6023e53b562dcad83b9254b198e81ee5"
38
38
  }
@@ -1,12 +1,79 @@
1
1
  // GIS
2
2
  import type {TypedArray} from '../types';
3
+ import type {Feature, Geometry, Point, LineString, Polygon} from 'geojson';
3
4
 
4
5
  // GEOJSON FORMAT GEOMETRY
5
6
 
6
7
  // eslint-disable-next-line import/no-unresolved
7
8
  export type {GeoJSON, Feature, Geometry, Position, GeoJsonProperties} from 'geojson';
8
9
  // eslint-disable-next-line import/no-unresolved
9
- export type {Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon} from 'geojson';
10
+ export type {
11
+ Point,
12
+ MultiPoint,
13
+ LineString,
14
+ MultiLineString,
15
+ Polygon,
16
+ MultiPolygon,
17
+ GeometryCollection
18
+ } from 'geojson';
19
+
20
+ // Aggregate information for converting GeoJSON into other formats
21
+ export type GeojsonGeometryInfo = {
22
+ coordLength: number;
23
+ pointPositionsCount: number;
24
+ pointFeaturesCount: number;
25
+ linePositionsCount: number;
26
+ linePathsCount: number;
27
+ lineFeaturesCount: number;
28
+ polygonPositionsCount: number;
29
+ polygonObjectsCount: number;
30
+ polygonRingsCount: number;
31
+ polygonFeaturesCount: number;
32
+ };
33
+
34
+ // FLAT GEOJSON FORMAT GEOMETRY
35
+ export type FlatGeometryType = 'Point' | 'LineString' | 'Polygon';
36
+ type RemoveCoordinatesField<Type> = {
37
+ [Property in keyof Type as Exclude<Property, 'coordinates'>]: Type[Property];
38
+ };
39
+
40
+ /**
41
+ * Generic flat geometry data storage type
42
+ */
43
+ export type FlatIndexedGeometry = {
44
+ data: number[];
45
+ indices: number[];
46
+ };
47
+
48
+ /**
49
+ * GeoJSON (Multi)Point geometry with coordinate data flattened into `data` array and indexed by `indices`
50
+ */
51
+ export type FlatPoint = RemoveCoordinatesField<Point> & FlatIndexedGeometry;
52
+
53
+ /**
54
+ * GeoJSON (Multi)LineString geometry with coordinate data flattened into `data` array and indexed by `indices`
55
+ */
56
+ export type FlatLineString = RemoveCoordinatesField<LineString> & FlatIndexedGeometry;
57
+
58
+ /**
59
+ * GeoJSON (Multi)Polygon geometry with coordinate data flattened into `data` array and indexed by 2D `indices`
60
+ */
61
+ export type FlatPolygon = RemoveCoordinatesField<Polygon> & {
62
+ data: number[];
63
+ indices: number[][];
64
+ areas: number[][];
65
+ };
66
+
67
+ export type FlatGeometry = FlatPoint | FlatLineString | FlatPolygon;
68
+
69
+ type FlattenGeometry<Type> = {
70
+ [Property in keyof Type]: Type[Property] extends Geometry ? FlatGeometry : Type[Property];
71
+ };
72
+
73
+ /**
74
+ * GeoJSON Feature with Geometry replaced by FlatGeometry
75
+ */
76
+ export type FlatFeature = FlattenGeometry<Feature>;
10
77
 
11
78
  // BINARY FORMAT GEOMETRY
12
79
 
@@ -37,6 +104,7 @@ export type BinaryPolygonGeometry = {
37
104
  positions: BinaryAttribute;
38
105
  polygonIndices: BinaryAttribute;
39
106
  primitivePolygonIndices: BinaryAttribute;
107
+ triangles?: BinaryAttribute;
40
108
  };
41
109
 
42
110
  export type BinaryProperties = {
package/src/index.ts CHANGED
@@ -55,7 +55,21 @@ export type {
55
55
  LineString,
56
56
  MultiLineString,
57
57
  Polygon,
58
- MultiPolygon
58
+ MultiPolygon,
59
+ GeometryCollection
60
+ } from './category/gis';
61
+
62
+ export type {GeojsonGeometryInfo} from './category/gis';
63
+
64
+ // GIS CATEGORY - FLAT GEOJSON
65
+ export type {
66
+ FlatFeature,
67
+ FlatIndexedGeometry,
68
+ FlatGeometry,
69
+ FlatGeometryType,
70
+ FlatPoint,
71
+ FlatLineString,
72
+ FlatPolygon
59
73
  } from './category/gis';
60
74
 
61
75
  // GIS CATEGORY - BINARY