Skip to main content

astroceleste_engine/catalog/
mod.rs

1//! Reference tables: fixed stars, lunar mansions, derived-house meanings.
2
3use serde::Serialize;
4
5#[allow(clippy::all)]
6#[rustfmt::skip]
7mod derived_meanings;
8#[allow(clippy::all)]
9#[rustfmt::skip]
10mod fixed_stars;
11#[allow(clippy::all)]
12#[rustfmt::skip]
13mod mansions;
14
15pub use derived_meanings::{DERIVED_HOUSE_MEANINGS, ROOT_HOUSE_THEMES};
16pub use fixed_stars::FIXED_STARS;
17pub use mansions::LUNAR_MANSIONS;
18
19/// A star with its tropical ecliptic position at J2000.0.
20#[derive(Debug, Clone, Copy, PartialEq)]
21pub struct FixedStar {
22    pub name: &'static str,
23    pub symbol: &'static str,
24    pub j2000_lon: f64,
25    pub j2000_lat: f64,
26    pub magnitude: f64,
27}
28
29/// One of the 28 lunar mansions (manazil al-qamar).
30#[derive(Debug, Clone, Copy, PartialEq, Serialize)]
31pub struct LunarMansion {
32    /// Mansion number (1-28).
33    pub number: u8,
34    /// Arabic name.
35    pub arabic_name: &'static str,
36    /// English name.
37    pub name: &'static str,
38    /// Sign or signs the mansion spans, e.g. "Aries - Taurus".
39    pub sign: &'static str,
40    /// Start, ecliptic longitude in degrees.
41    pub degree_start: f64,
42    /// End, ecliptic longitude in degrees.
43    pub degree_end: f64,
44}
45
46/// What a derived house signifies, in English and Italian.
47#[derive(Debug, Clone, Copy, PartialEq, Serialize)]
48pub struct Meaning {
49    pub en: &'static str,
50    pub it: &'static str,
51}