pystac.extensions.table¶
Implements the Table Extension.
- class pystac.extensions.table.AssetTableExtension(asset: Asset)[source]¶
A concrete implementation of
TableExtension
on anAsset
that extends the Asset fields to include properties defined in the Table Extension.This class should generally not be instantiated directly. Instead, call
TableExtension.ext()
on anAsset
to extend it.- asset_href: str¶
- properties: dict[str, Any]¶
The properties that this extension wraps.
The extension which implements PropertiesExtension can use
_get_property
and_set_property
to get and set values on this instance. Note that _set_properties mutates the properties directly.
- property storage_options: dict[str, Any] | None¶
Additional keywords for opening the dataset
- class pystac.extensions.table.CollectionTableExtension(collection: Collection)[source]¶
A concrete implementation of
TableExtension
on aCollection
that extends the properties of the Item to include properties defined in the Table Extension.This class should generally not be instantiated directly. Instead, call
TableExtension.ext()
on anCollection
to extend it.- collection: pystac.Collection¶
- properties: dict[str, Any]¶
The properties that this extension wraps.
The extension which implements PropertiesExtension can use
_get_property
and_set_property
to get and set values on this instance. Note that _set_properties mutates the properties directly.
- class pystac.extensions.table.Column(properties: dict[str, Any])[source]¶
Object representing a column of a table.
- property col_type: str | None¶
Data type of the column. If using a file format with a type system (like Parquet), we recommend you use those types
- property description: str | None¶
Detailed multi-line description to explain the column. CommonMark 0.29 syntax MAY be used for rich text representation.
- property name: str¶
The column name
- properties: dict[str, Any]¶
- class pystac.extensions.table.ItemAssetsTableExtension(item_asset: AssetDefinition)[source]¶
- asset_defn: item_assets.AssetDefinition¶
- properties: dict[str, Any]¶
The properties that this extension wraps.
The extension which implements PropertiesExtension can use
_get_property
and_set_property
to get and set values on this instance. Note that _set_properties mutates the properties directly.
- class pystac.extensions.table.ItemTableExtension(item: Item)[source]¶
A concrete implementation of
TableExtension
on anItem
that extends the properties of the Item to include properties defined in the Table Extension.This class should generally not be instantiated directly. Instead, call
TableExtension.ext()
on anItem
to extend it.- item: pystac.Item¶
- properties: dict[str, Any]¶
The properties that this extension wraps.
The extension which implements PropertiesExtension can use
_get_property
and_set_property
to get and set values on this instance. Note that _set_properties mutates the properties directly.
- class pystac.extensions.table.Table(properties: dict[str, Any])[source]¶
Object containing a high-level summary about a table
- property description: str | None¶
Detailed multi-line description to explain the table. CommonMark 0.29 syntax MAY be used for rich text representation.
- property name: str¶
The table name
- properties: dict[str, Any]¶
- class pystac.extensions.table.TableExtensinoHooks[source]¶
- prev_extension_ids = {'https://stac-extensions.github.io/table/v1.0.0/schema.json', 'https://stac-extensions.github.io/table/v1.0.1/schema.json', 'https://stac-extensions.github.io/table/v1.1.0/schema.json', 'table'}¶
- schema_uri: str = 'https://stac-extensions.github.io/table/v1.2.0/schema.json'¶
- stac_object_types = {Collection, Feature}¶
- class pystac.extensions.table.TableExtension[source]¶
An abstract class that can be used to extend the properties of a
Collection
,Item
, orAsset
with properties from the Datacube Extension. This class is generic over the type of STAC Object to be extended (e.g.Item
,Asset
).To create a concrete instance of
TableExtension
, use theTableExtension.ext()
method. For example:>>> item: pystac.Item = ... >>> tbl_ext = TableExtension.ext(item)
- classmethod ext(obj: T, add_if_missing: bool = False) TableExtension[T] [source]¶
Extend the given STAC Object with properties from the Table Extension.
This extension can be applied to instances of
Collection
,Item
orAsset
.- Raises:
pystac.ExtensionTypeError – If an invalid object type is passed.
- name: Literal['table'] = 'table'¶
- property primary_geometry: str | None¶
The primary geometry column name
- property row_count: int | None¶
The number of rows in the dataset