pub struct ObservationSlices<'a> {
pub ids: &'a [u64],
pub times_mjd: &'a [f64],
pub ra: &'a [f64],
pub dec: &'a [f64],
pub nights: &'a [i64],
pub object_ids: &'a [u64],
pub observatory_codes: &'a [u32],
}Expand description
Borrowed slice view into observation data.
Created once at API entry points from an &impl ObservationTable,
then passed to all internal functions. This keeps generics out of
the algorithm code.
Fields§
§ids: &'a [u64]§times_mjd: &'a [f64]§ra: &'a [f64]§dec: &'a [f64]§nights: &'a [i64]§object_ids: &'a [u64]§observatory_codes: &'a [u32]Implementations§
Source§impl<'a> ObservationSlices<'a>
impl<'a> ObservationSlices<'a>
Sourcepub fn from_table(table: &'a impl ObservationTable) -> Self
pub fn from_table(table: &'a impl ObservationTable) -> Self
Extract slices from any ObservationTable implementor.
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Auto Trait Implementations§
impl<'a> Freeze for ObservationSlices<'a>
impl<'a> RefUnwindSafe for ObservationSlices<'a>
impl<'a> Send for ObservationSlices<'a>
impl<'a> Sync for ObservationSlices<'a>
impl<'a> Unpin for ObservationSlices<'a>
impl<'a> UnsafeUnpin for ObservationSlices<'a>
impl<'a> UnwindSafe for ObservationSlices<'a>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more