gaia_access 0.2.0

Access the Gaia ESA Archive for astronomical data.
Documentation
// This code is generated by generate_code.py, do not modify it manually.

//! This module contains all the known columns in the ravedr5_join table.

use crate::traits::{Column, Table};

/// Convenience table to be used to join RAVE DR5 catalogue with the
/// cross-match results. The table links the external catalogue original
/// sourceId (originalExtSourceId) to the corresponding the additional
/// numerical identifier (cleanRavedr5Oid).
/// Both originalExtSourceId and cleanRavedr5Oid are present in the
/// cross-match output tables (ravedr5BestNeighbour and
/// ravedr5Neighbourhood). However, in case there are suspected duplicates
/// in the external catalogue, different originalExtSourceId will correspond
/// to the same cleanRavedr5Oid.
/// In the cross-match output table only the originalExtSourceId of the
/// source with the best astrometry among the suspected duplicates will be
/// listed.
/// In practice, users may use the originalExtSourceId in the original
/// catalogue to find the matching source with the best astrometry. Users
/// interested to find all matching suspected duplicates should instead use
/// the cleanRavedr5Oid in the join with the cross-match result tables.
/// See Documentation, [chap:crossmatch], for more details on the duplicates
/// in the external catalogues and their treatment in the cross-match
/// computations.
#[allow(non_camel_case_types)]
pub struct ravedr5_join;

impl Table for ravedr5_join {
    fn string(&self) -> String {
        "ravedr5_join".to_string()
    }
}

/// The columns in the ravedr5_join table.
#[allow(non_camel_case_types)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, strum::Display)]
pub enum Col {
    /// Original External Catalogue source identifier
    original_ext_source_id,
    /// External Catalogue source identifier
    clean_ravedr5_oid,
}

impl Column for Col {}

#[cfg(test)]
/// Collects all the known columns in the ravedr5_join table.
pub fn collect_known(map: &mut std::collections::HashMap<String, Vec<String>>) {
    let mut col_strings = Vec::new();
    col_strings.push(Col::original_ext_source_id.to_string());
    col_strings.push(Col::clean_ravedr5_oid.to_string());
    map.insert(ravedr5_join.string(), col_strings);
}