Abstract base class with methods for adding and removing extensions from STAC Objects. This class is generic over the type of object being extended (e.g. Item
).
Concrete extension implementations should inherit from this class and either provide a concrete type or a bounded type variable.
See EOExtension
for an example implementation.
Add the schema URI for this extension to the stac_extensions
list for the given object, if it is not already present.
Given a STACObject
, checks if the object has this extension’s schema URI in its stac_extensions
list. If add_if_missing
is True
, the schema URI will be added to the object.
obj – The object to validate.
add_if_missing – Whether to add the schema URI to the object if it is not already present. Defaults to False.
Given an Asset
, checks if the asset’s owner has this extension’s schema URI in its stac_extensions
list. If add_if_missing
is True
, the schema URI will be added to the owner.
asset – The asset whose owner should be validated.
add_if_missing – Whether to add the schema URI to the owner if it is not already present. Defaults to False.
STACError – If add_if_missing
is True
and asset.owner
is None
.
Gets the schema URI associated with this extension.
Gets a list of schema URIs associated with this extension.
Check if the given object implements this extension by checking pystac.STACObject.stac_extensions
for this extension’s schema URI.
Remove the schema URI for this extension from the pystac.STACObject.stac_extensions
list for the given object.
DEPRECATED
Deprecated since version 1.9: Use ensure_has_extension()
instead.
Given a STACObject
, checks if the object has this extension’s schema URI in its stac_extensions
list. If add_if_missing
is True
, the schema URI will be added to the object.
obj – The object to validate.
add_if_missing – Whether to add the schema URI to the object if it is not already present. Defaults to False.
DEPRECATED
Deprecated since version 1.9: Use ensure_owner_has_extension()
instead.
Given an Asset
, checks if the asset’s owner has this extension’s schema URI in its stac_extensions
list. If add_if_missing
is True
, the schema URI will be added to the owner.
asset – The asset whose owner should be validated.
add_if_missing – Whether to add the schema URI to the owner if it is not already present. Defaults to False.
STACError – If add_if_missing
is True
and asset.owner
is None
.
Abstract base class for extending the properties of an Item
to include properties defined by a STAC Extension.
This class should not be instantiated directly. Instead, create an extension-specific class that inherits from this class and instantiate that. See EOExtension
for an example.
Additional read-only properties accessible from the extended object.
These are used when extending an Asset
to give access to the properties of the owning Item
. If a property exists in both additional_read_properties
and properties
, the value in additional_read_properties
will take precedence.
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.
Base class for extending the properties in pystac.Collection.summaries
to include properties defined by a STAC Extension.
This class should generally not be instantiated directly. Instead, create an extension-specific class that inherits from this class and instantiate that. See SummariesEOExtension
for an example.
The summaries for the Collection
being extended.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4