Skip to main content

Class: ParquetTableDataProvider

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:15

Data provider for tabular data

Implements​

Constructors​

Constructor​

new ParquetTableDataProvider(): ParquetTableDataProvider

Returns​

ParquetTableDataProvider

Properties​

name​

readonly name: "Parquet" = "Parquet"

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:23

The name of the data provider

Implementation of​

TableDataProvider.name


schema​

readonly schema: object

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:25

The JSON schema for the data source

properties​

properties: object

properties.idColumn​

idColumn: object

properties.idColumn.type​

type: string = "string"

properties.nameColumn​

nameColumn: object

properties.nameColumn.type​

type: string = "string"

properties.requestHeaders​

requestHeaders: object

properties.requestHeaders.additionalProperties​

additionalProperties: object

properties.requestHeaders.additionalProperties.type​

type: string = "string"

properties.requestHeaders.type​

type: string = "object"

properties.source​

source: object

properties.source.type​

type: string = "string"

required​

required: string[]

type​

type: string = "object"

Implementation of​

TableDataProvider.schema


uischema​

readonly uischema: object

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:45

The JSON Forms UI schema for the data source

It must not contain a control for the data source's source, which the application renders itself if the schema declares it, as a string.

elements​

elements: object[]

type​

type: string = "VerticalLayout"

Implementation of​

TableDataProvider.uischema

Methods​

load()​

load(normalizedDataSource, options?): Promise<ParquetTableData>

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:93

Opens a data source and returns the loaded data accessor

The data source has to have been normalized by DataProvider.normalize beforehand.

Parameters​

normalizedDataSource​

NormalizedParquetTableDataSource

The normalized data source to open

options?​

DataProviderLoadOptions

See DataProviderLoadOptions

Returns​

Promise<ParquetTableData>

A promise that resolves to the loaded data accessor

Implementation of​

TableDataProvider.load


normalize()​

normalize(dataSource, workspace, projectSource): NormalizedParquetTableDataSource

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:61

Returns the data source with all of this data provider's defaults applied and its source normalized

Data sources that normalize to the same value are considered equal, and their data is loaded only once and shared between all referencing objects. Normalization has to be idempotent: normalizing an already normalized data source must return the same value again.

The source is normalized with SourceUtils.normalizeSource, which resolves it against the project source and the open workspace, so the result has to be recomputed when either changes.

Normalizing may throw, e.g. for a source that cannot be resolved against the given workspace and project source. The data cache catches it, so only the objects referencing that data source fail to load; the data of all other objects is unaffected.

Parameters​

dataSource​

ParquetTableDataSource

The data source to normalize

workspace​

FileSystemDirectoryHandle | null

The directory handle of the open workspace, if any

projectSource​

string | null

Where the project was loaded from: its absolute URL, the workspace-relative path of the project file, or null for projects that were loaded from neither

Returns​

NormalizedParquetTableDataSource

The normalized data source

Implementation of​

TableDataProvider.normalize


supports()​

supports(normalizedSource): Promise<boolean>

Defined in: @tissuumaps-storage/src/parquet/ParquetTableDataProvider.ts:85

Returns whether a source has a Parquet or GeoParquet file extension (see ParquetTableDataProvider._extensions), as the point geometry of GeoParquet files is read as coordinate columns

Parameters​

normalizedSource​

string

The normalized source to check

Returns​

Promise<boolean>

A promise that resolves to whether the source is supported

Implementation of​

TableDataProvider.supports