pub struct MmapPreciseEphemerisInterpolant<'a> { /* private fields */ }Expand description
Evaluation-only precise-ephemeris interpolant backed by store bytes.
Self::from_path reads the artifact and validates its checksum on open.
Self::from_bytes accepts caller-managed bytes, including an mmap slice
from an application-owned mapping. Both paths parse only fixed metadata;
clock spline coefficients are consumed from the artifact as written.
Implementations§
Source§impl MmapPreciseEphemerisInterpolant<'static>
impl MmapPreciseEphemerisInterpolant<'static>
Sourcepub fn from_vec(
bytes: Vec<u8>,
) -> Result<MmapPreciseEphemerisInterpolant<'static>, PreciseInterpolantStoreError>
pub fn from_vec( bytes: Vec<u8>, ) -> Result<MmapPreciseEphemerisInterpolant<'static>, PreciseInterpolantStoreError>
Parse an owned precise-interpolant store byte vector.
Sourcepub fn from_path(
path: impl AsRef<Path>,
) -> Result<MmapPreciseEphemerisInterpolant<'static>, PreciseInterpolantStoreError>
pub fn from_path( path: impl AsRef<Path>, ) -> Result<MmapPreciseEphemerisInterpolant<'static>, PreciseInterpolantStoreError>
Read and parse a precise-interpolant store file.
This reads the file into memory. Applications that already manage an mmap
should pass the mmap slice to MmapPreciseEphemerisInterpolant::from_bytes
to avoid the file read copy.
Source§impl<'a> MmapPreciseEphemerisInterpolant<'a>
impl<'a> MmapPreciseEphemerisInterpolant<'a>
Sourcepub fn from_bytes(
bytes: &'a [u8],
) -> Result<MmapPreciseEphemerisInterpolant<'a>, PreciseInterpolantStoreError>
pub fn from_bytes( bytes: &'a [u8], ) -> Result<MmapPreciseEphemerisInterpolant<'a>, PreciseInterpolantStoreError>
Parse a borrowed precise-interpolant store byte span.
The reader keeps the byte span in place. F64 payload arrays are borrowed directly from the span, so callers that pass an mmap-backed slice get a zero-copy reader.
Sourcepub fn checksum64(&self) -> u64
pub fn checksum64(&self) -> u64
Return the store’s file-level checksum.
Sourcepub const fn time_scale(&self) -> TimeScale
pub const fn time_scale(&self) -> TimeScale
The time scale of the stored epoch axis.
Sourcepub fn satellites(&self) -> &[GnssSatelliteId]
pub fn satellites(&self) -> &[GnssSatelliteId]
The satellites present in the mapped artifact, in ascending order.
Sourcepub fn position_at_j2000_seconds(
&self,
sat: GnssSatelliteId,
query: f64,
) -> Result<Sp3State, Error>
pub fn position_at_j2000_seconds( &self, sat: GnssSatelliteId, query: f64, ) -> Result<Sp3State, Error>
Interpolate the state of sat at an arbitrary J2000-second epoch.
Sourcepub fn position(
&self,
sat: GnssSatelliteId,
epoch: Instant,
) -> Result<Sp3State, Error>
pub fn position( &self, sat: GnssSatelliteId, epoch: Instant, ) -> Result<Sp3State, Error>
Interpolate the state of sat at an arbitrary Instant.
The query instant must use the same time scale as the source artifact.
Sourcepub fn observable_states_at_j2000_s(
&self,
satellites: &[GnssSatelliteId],
epochs_j2000_s: &[f64],
) -> Result<ObservableStateBatch, ObservablesError>
pub fn observable_states_at_j2000_s( &self, satellites: &[GnssSatelliteId], epochs_j2000_s: &[f64], ) -> Result<ObservableStateBatch, ObservablesError>
ECEF states for parallel satellite and epoch arrays.
ECEF states for many satellites at one shared epoch.
Trait Implementations§
Source§impl Debug for MmapPreciseEphemerisInterpolant<'_>
impl Debug for MmapPreciseEphemerisInterpolant<'_>
Source§impl EphemerisSource for MmapPreciseEphemerisInterpolant<'_>
impl EphemerisSource for MmapPreciseEphemerisInterpolant<'_>
Source§fn position_clock_at_j2000_s(
&self,
sat: GnssSatelliteId,
t_j2000_s: f64,
) -> Option<([f64; 3], f64)>
fn position_clock_at_j2000_s( &self, sat: GnssSatelliteId, t_j2000_s: f64, ) -> Option<([f64; 3], f64)>
sat at t_j2000_s.Source§impl ObservableEphemerisSource for MmapPreciseEphemerisInterpolant<'_>
impl ObservableEphemerisSource for MmapPreciseEphemerisInterpolant<'_>
Source§fn observable_state_at_j2000_s(
&self,
sat: GnssSatelliteId,
t_j2000_s: f64,
) -> Result<ObservableState, ObservablesError>
fn observable_state_at_j2000_s( &self, sat: GnssSatelliteId, t_j2000_s: f64, ) -> Result<ObservableState, ObservablesError>
Source§fn observable_states_at_j2000_s(
&self,
satellites: &[GnssSatelliteId],
epochs_j2000_s: &[f64],
) -> Result<ObservableStateBatch, ObservablesError>
fn observable_states_at_j2000_s( &self, satellites: &[GnssSatelliteId], epochs_j2000_s: &[f64], ) -> Result<ObservableStateBatch, ObservablesError>
Auto Trait Implementations§
impl<'a> Freeze for MmapPreciseEphemerisInterpolant<'a>
impl<'a> RefUnwindSafe for MmapPreciseEphemerisInterpolant<'a>
impl<'a> Send for MmapPreciseEphemerisInterpolant<'a>
impl<'a> Sync for MmapPreciseEphemerisInterpolant<'a>
impl<'a> Unpin for MmapPreciseEphemerisInterpolant<'a>
impl<'a> UnsafeUnpin for MmapPreciseEphemerisInterpolant<'a>
impl<'a> UnwindSafe for MmapPreciseEphemerisInterpolant<'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
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>
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>
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.