gaia_access 0.1.4

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 lens_candidates table.

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

/// This table contains the sources identified as possible gravitational lens candidates based on an analysis of the observations in the neighbourhoud of a list of sources selected from a compilation of quasar candidates. Information about the catalogues from which these quasars proceed is given in the table of lens catalogue names.
#[allow(non_camel_case_types)]
pub struct lens_candidates;

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

/// The columns in the lens_candidates table.
#[allow(non_camel_case_types)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, strum::Display)]
pub enum Col {
    /// Solution Identifier
    solution_id,
    /// Unique source identifier
    source_id,
    /// The name of the gravitational lens candidate
    name,
    /// GravLens flag
    flag,
    /// Number of components
    n_components,
    /// Index of the component for this sourceId
    component_id,
    /// Number of valid observations used for this component
    n_obs_component,
    /// Component object flag
    component_flag,
    /// Mean right ascension of the component
    ra_component,
    /// Standard deviation of the right ascension of the component
    ra_std_component,
    /// Mean declination of the clusters of measurements
    dec_component,
    /// Standard deviation of the declination measurements
    dec_std_component,
    /// Mean G flux of the component
    g_flux_component,
    /// Uncertainty of the mean flux value for this component
    g_flux_component_error,
    /// Mean onboard G magnitude of the component
    g_mag_component,
    /// Standard deviation of the onboard G magnitude of the component
    g_mag_std_component,
}

impl Column for Col {}

#[cfg(test)]
/// Collects all the known columns in the lens_candidates table.
pub fn collect_known(map: &mut std::collections::HashMap<String, Vec<String>>) {
    let mut col_strings = Vec::new();
    col_strings.push(Col::solution_id.to_string());
    col_strings.push(Col::source_id.to_string());
    col_strings.push(Col::name.to_string());
    col_strings.push(Col::flag.to_string());
    col_strings.push(Col::n_components.to_string());
    col_strings.push(Col::component_id.to_string());
    col_strings.push(Col::n_obs_component.to_string());
    col_strings.push(Col::component_flag.to_string());
    col_strings.push(Col::ra_component.to_string());
    col_strings.push(Col::ra_std_component.to_string());
    col_strings.push(Col::dec_component.to_string());
    col_strings.push(Col::dec_std_component.to_string());
    col_strings.push(Col::g_flux_component.to_string());
    col_strings.push(Col::g_flux_component_error.to_string());
    col_strings.push(Col::g_mag_component.to_string());
    col_strings.push(Col::g_mag_std_component.to_string());
    map.insert(lens_candidates.string(), col_strings);
}