pub struct SunEvents { /* private fields */ }Expand description
This struct allows one to create iterators over sun events moving forward or backward in time.
Implementations§
Source§impl SunEvents
impl SunEvents
Sourcepub fn starting_from(
start_date: DateTime<Utc>,
position: GlobalPosition,
event_whitelist: &[SunEvent],
) -> Self
pub fn starting_from( start_date: DateTime<Utc>, position: GlobalPosition, event_whitelist: &[SunEvent], ) -> Self
List SunEvents starting from the start_date, computed at position,
including only the SunEvents listed in the event_whitelist.
§Panics
Panics when event_whitelist is empty.
Sourcepub fn forecast(self) -> ForecastedSunEvents ⓘ
pub fn forecast(self) -> ForecastedSunEvents ⓘ
List SunEvents occurring after the start_date.
Sourcepub fn history(self) -> HistoricSunEvents ⓘ
pub fn history(self) -> HistoricSunEvents ⓘ
List SunEvents occurring before the start_date.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SunEvents
impl RefUnwindSafe for SunEvents
impl Send for SunEvents
impl Sync for SunEvents
impl Unpin for SunEvents
impl UnwindSafe for SunEvents
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more