Skip to content
import { getParquetLayerInfo } from "@arcgis/core/layers/support/parquetUtils.js";
Since
ArcGIS Maps SDK for JavaScript 4.33

Provides utility functions for the ParquetLayer.

See also

Type definitions

ParquetLayerInfo

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

Contains an information inferred from the parquet files.

See also

urls

Property
Type
Collection<string>
Since
ArcGIS Maps SDK for JavaScript 5.0

A collection of URLs pointing to the parquet files.

fields

Property
Type
Field[] | undefined
Since
ArcGIS Maps SDK for JavaScript 5.0

The fields derived from the parquet files.

geometryEncoding

Property
Type
ParquetGeometryEncodingUnion | null | undefined
Since
ArcGIS Maps SDK for JavaScript 5.0

The encoding format used to store geometries in the parquet files. See ParquetLayer.geometryEncoding for more information.

geometryType

Property
Type
ParquetGeometryType | null | undefined
Since
ArcGIS Maps SDK for JavaScript 5.0

The geometry type of the features in the layer.

spatialReference

Property
Type
SpatialReference | undefined
Since
ArcGIS Maps SDK for JavaScript 5.0

The spatial reference of the layer.

ParquetGeometryType

Type definition

The geometry type of the layer’s features, inferred from the Parquet file and returned by getParquetLayerInfo().

See also
Type
"point" | "polygon" | "polyline" | "multipoint"

ParquetLayerInfoOptions

Type definition

Options for the getParquetLayerInfo() function.

Supertypes
AbortOptions

customParameters

Property
Type
CustomParameters | null | undefined

A list of key-value pairs of parameters to append to the url.

Functions

getParquetLayerInfo

Function

Retrieves information about a ParquetLayer from the first parquet file in the specified URLs array. Throws an error if the parquet file is empty or if the information cannot be determined.

Signature
getParquetLayerInfo (urls: string[], options?: ParquetLayerInfoOptions): Promise<ParquetLayerInfo>
Parameters
ParameterTypeDescriptionRequired
urls
string[]

An array of URLs pointing to parquet files. At least one url must be provided.

options

An object specifying additional options. See ParquetLayerInfoOptions for details.

Returns
Promise<ParquetLayerInfo>

A promise that resolves to the parquet layer information.

Example
const urls = ["url-to-your-parquet-file.parquet"];
const info = await parquetUtils.getParquetLayerInfo(urls);
// create new parquet layer using the retrieved info
const layer = new ParquetLayer(info);