pub struct Caches { /* private fields */ }
Implementations§
source§impl Caches
impl Caches
sourcepub fn stats(&self) -> CachesStats
pub fn stats(&self) -> CachesStats
Computes the stats for all primary caches.
source§impl Caches
impl Caches
sourcepub fn latest_at_component_with_log_level<C: Component>(
&self,
store: &DataStore,
resolver: &PromiseResolver,
entity_path: &EntityPath,
query: &LatestAtQuery,
level: Level
) -> Option<LatestAtMonoResult<C>>
pub fn latest_at_component_with_log_level<C: Component>( &self, store: &DataStore, resolver: &PromiseResolver, entity_path: &EntityPath, query: &LatestAtQuery, level: Level ) -> Option<LatestAtMonoResult<C>>
Get the latest index and value for a given dense re_types_core::Component
.
Returns None
if the data is a promise that has yet to be resolved.
This assumes that the row we get from the store contains at most one instance for this
component; it will generate a log message of level
otherwise.
This should only be used for “mono-components” such as Transform
and Tensor
.
This is a best-effort helper, it will merely log messages on failure.
sourcepub fn latest_at_component<C: Component>(
&self,
store: &DataStore,
resolver: &PromiseResolver,
entity_path: &EntityPath,
query: &LatestAtQuery
) -> Option<LatestAtMonoResult<C>>
pub fn latest_at_component<C: Component>( &self, store: &DataStore, resolver: &PromiseResolver, entity_path: &EntityPath, query: &LatestAtQuery ) -> Option<LatestAtMonoResult<C>>
Get the latest index and value for a given dense re_types_core::Component
.
This assumes that the row we get from the store contains at most one instance for this component; it will log a warning otherwise.
This should only be used for “mono-components” such as Transform
and Tensor
.
This is a best-effort helper, it will merely log errors on failure.
sourcepub fn latest_at_component_quiet<C: Component>(
&self,
store: &DataStore,
resolver: &PromiseResolver,
entity_path: &EntityPath,
query: &LatestAtQuery
) -> Option<LatestAtMonoResult<C>>
pub fn latest_at_component_quiet<C: Component>( &self, store: &DataStore, resolver: &PromiseResolver, entity_path: &EntityPath, query: &LatestAtQuery ) -> Option<LatestAtMonoResult<C>>
Get the latest index and value for a given dense re_types_core::Component
.
This assumes that the row we get from the store contains at most one instance for this component; it will return None and log a debug message otherwise.
This should only be used for “mono-components” such as Transform
and Tensor
.
This is a best-effort helper, it will merely logs debug messages on failure.
sourcepub fn latest_at_component_at_closest_ancestor<C: Component>(
&self,
store: &DataStore,
resolver: &PromiseResolver,
entity_path: &EntityPath,
query: &LatestAtQuery
) -> Option<(EntityPath, LatestAtMonoResult<C>)>
pub fn latest_at_component_at_closest_ancestor<C: Component>( &self, store: &DataStore, resolver: &PromiseResolver, entity_path: &EntityPath, query: &LatestAtQuery ) -> Option<(EntityPath, LatestAtMonoResult<C>)>
Call Self::latest_at_component
at the given path, walking up the hierarchy until an instance is found.
source§impl Caches
impl Caches
sourcepub fn latest_at(
&self,
store: &DataStore,
query: &LatestAtQuery,
entity_path: &EntityPath,
component_names: impl IntoIterator<Item = ComponentName>
) -> LatestAtResults
pub fn latest_at( &self, store: &DataStore, query: &LatestAtQuery, entity_path: &EntityPath, component_names: impl IntoIterator<Item = ComponentName> ) -> LatestAtResults
Queries for the given component_names
using latest-at semantics.
See LatestAtResults
for more information about how to handle the results.
This is a cached API – data will be lazily cached upon access.
source§impl Caches
impl Caches
sourcepub fn range(
&self,
store: &DataStore,
query: &RangeQuery,
entity_path: &EntityPath,
component_names: impl IntoIterator<Item = ComponentName>
) -> RangeResults
pub fn range( &self, store: &DataStore, query: &RangeQuery, entity_path: &EntityPath, component_names: impl IntoIterator<Item = ComponentName> ) -> RangeResults
Queries for the given component_names
using range semantics.
See RangeResults
for more information about how to handle the results.
This is a cached API – data will be lazily cached upon access.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Caches
impl !RefUnwindSafe for Caches
impl Send for Caches
impl Sync for Caches
impl Unpin for Caches
impl !UnwindSafe for Caches
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> CheckedAs for T
impl<T> CheckedAs for T
source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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 more