lsst.dax.apdb g9290983e33+d2d81de7f7
 
Loading...
Searching...
No Matches
lsst.dax.apdb.apdbAdmin.ApdbAdmin Class Reference
Inheritance diagram for lsst.dax.apdb.apdbAdmin.ApdbAdmin:
lsst.dax.apdb.cassandra.apdbCassandraAdmin.ApdbCassandraAdmin lsst.dax.apdb.sql.apdbSqlAdmin.ApdbSqlAdmin

Public Member Functions

int apdb_part (self, float ra_deg, float dec_deg)
 
int apdb_time_part (self, float midpointMjdTai)
 
None delete_records (self, Iterable[DiaObjectLocator] objects, Iterable[DiaSourceLocator] sources, Iterable[DiaForcedSourceLocator] forced_sources)
 

Detailed Description

Abstract interface for administrative tasks for APDB.

Member Function Documentation

◆ apdb_part()

int lsst.dax.apdb.apdbAdmin.ApdbAdmin.apdb_part ( self,
float ra_deg,
float dec_deg )
Return spatial partition index for given coordinates.

Parameters
----------
ra_deg, dec_deg : `float`
    Spatial coordinates, in degrees.

Returns
-------
index : `int`
    Spatial partition index.

Reimplemented in lsst.dax.apdb.cassandra.apdbCassandraAdmin.ApdbCassandraAdmin, and lsst.dax.apdb.sql.apdbSqlAdmin.ApdbSqlAdmin.

◆ apdb_time_part()

int lsst.dax.apdb.apdbAdmin.ApdbAdmin.apdb_time_part ( self,
float midpointMjdTai )
Return temporal partition index for given time.

Parameters
----------
midpointMjdTai : `float`
    Time in MJD.

Returns
-------
index : `int`
    Temporal partition index.

Reimplemented in lsst.dax.apdb.cassandra.apdbCassandraAdmin.ApdbCassandraAdmin, and lsst.dax.apdb.sql.apdbSqlAdmin.ApdbSqlAdmin.

◆ delete_records()

None lsst.dax.apdb.apdbAdmin.ApdbAdmin.delete_records ( self,
Iterable[DiaObjectLocator] objects,
Iterable[DiaSourceLocator] sources,
Iterable[DiaForcedSourceLocator] forced_sources )
Remove DiaObjects and all their associated DiaSources and
DiaForcedSources from database.

Parameters
----------
objects : `~collections.abc.Iterable` [`DiaObjectLocator`]
    Locators for DiaObject records to remove.
sources : `~collections.abc.Iterable` [`DiaSourceLocator`]
    Locators for DiaSource records to remove.
forced_sources : `~collections.abc.Iterable` [`DiaSourceLocator`]
    Locators for DiaForcedSource records to remove.

Notes
-----
The list of sources has to include all sources associated with objects
in ``objects`` list. Sources that are not associated with any object
from ``objects`` are not removed.

Reimplemented in lsst.dax.apdb.cassandra.apdbCassandraAdmin.ApdbCassandraAdmin, and lsst.dax.apdb.sql.apdbSqlAdmin.ApdbSqlAdmin.


The documentation for this class was generated from the following file: