StoredDatastoreItemInfo

class lsst.daf.butler.StoredDatastoreItemInfo

Bases: object

Internal information associated with a stored dataset in a Datastore.

This is an empty base class. Datastore implementations are expected to write their own subclasses.

Attributes Summary

dataset_id

Dataset ID associated with this record (DatasetId)

Methods Summary

file_location(factory)

Return the location of artifact.

from_record(record)

Create instance from database record.

to_record()

Convert record contents to a dictionary.

Attributes Documentation

dataset_id

Dataset ID associated with this record (DatasetId)

Methods Documentation

file_location(factory: LocationFactory) Location

Return the location of artifact.

Parameters:
factoryLocationFactory

Factory relevant to the datastore represented by this item.

Returns:
locationLocation

The location of the item within this datastore.

classmethod from_record(record: Mapping[str, Any]) StoredDatastoreItemInfo

Create instance from database record.

Parameters:
recorddict

The record associated with this item.

Returns:
infoinstance of the relevant type.

The newly-constructed item corresponding to the record.

to_record() Dict[str, Any]

Convert record contents to a dictionary.