Struct rerun::TimePoint

source ·
pub struct TimePoint(/* private fields */);
Expand description

A point in time on any number of Timelines.

It can be represented by Time, a sequence index, or a mix of several things.

If this is empty, the data is timeless. Timeless data will show up on all timelines, past and future, and will hit all time queries. In other words, it is always there.

Implementations§

source§

impl TimePoint

source

pub fn timeless() -> TimePoint

Logging to this time means the data will show upp in all timelines, past and future. The time will be TimeInt::BEGINNING, meaning it will always be in range for any time query.

source

pub fn get(&self, timeline: &Timeline) -> Option<&TimeInt>

source

pub fn insert(&mut self, timeline: Timeline, time: TimeInt) -> Option<TimeInt>

source

pub fn remove(&mut self, timeline: &Timeline) -> Option<TimeInt>

source

pub fn is_timeless(&self) -> bool

source

pub fn is_empty(&self) -> bool

source

pub fn timelines(&self) -> impl ExactSizeIterator

source

pub fn times(&self) -> impl ExactSizeIterator

source

pub fn iter(&self) -> impl ExactSizeIterator

source

pub fn union_max(self, rhs: &TimePoint) -> TimePoint

Computes the union of two TimePoints, keeping the maximum time value in case of conflicts.

Trait Implementations§

source§

impl Clone for TimePoint

source§

fn clone(&self) -> TimePoint

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl DataUi for TimePoint

§

fn data_ui( &self, ctx: &mut ViewerContext<'_>, ui: &mut Ui, _verbosity: UiVerbosity, _query: &LatestAtQuery )

If you need to lookup something in the data store, use the given query to do so.
source§

impl Debug for TimePoint

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for TimePoint

source§

fn default() -> TimePoint

Returns the “default value” for a type. Read more
source§

impl<'de> Deserialize<'de> for TimePoint

source§

fn deserialize<__D>( __deserializer: __D ) -> Result<TimePoint, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl<const N: usize> From<[(Timeline, TimeInt); N]> for TimePoint

source§

fn from(timelines: [(Timeline, TimeInt); N]) -> TimePoint

Converts to this type from the input type.
source§

impl From<BTreeMap<Timeline, TimeInt>> for TimePoint

source§

fn from(timelines: BTreeMap<Timeline, TimeInt>) -> TimePoint

Converts to this type from the input type.
source§

impl FromIterator<(Timeline, TimeInt)> for TimePoint

source§

fn from_iter<T>(iter: T) -> TimePointwhere T: IntoIterator<Item = (Timeline, TimeInt)>,

Creates a value from an iterator. Read more
source§

impl Hash for TimePoint

source§

fn hash<__H>(&self, state: &mut __H)where __H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<'a> IntoIterator for &'a TimePoint

§

type Item = (&'a Timeline, &'a TimeInt)

The type of the elements being iterated over.
§

type IntoIter = Iter<'a, Timeline, TimeInt>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> <&'a TimePoint as IntoIterator>::IntoIter

Creates an iterator from a value. Read more
source§

impl IntoIterator for TimePoint

§

type Item = (Timeline, TimeInt)

The type of the elements being iterated over.
§

type IntoIter = IntoIter<Timeline, TimeInt>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> <TimePoint as IntoIterator>::IntoIter

Creates an iterator from a value. Read more
source§

impl Ord for TimePoint

source§

fn cmp(&self, other: &TimePoint) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Selfwhere Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl PartialEq for TimePoint

source§

fn eq(&self, other: &TimePoint) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for TimePoint

source§

fn partial_cmp(&self, other: &TimePoint) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl Serialize for TimePoint

source§

fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl SizeBytes for TimePoint

source§

fn heap_size_bytes(&self) -> u64

Returns the total size of self on the heap, in bytes.
§

fn total_size_bytes(&self) -> u64

Returns the total size of self in bytes, accounting for both stack and heap space.
§

fn stack_size_bytes(&self) -> u64

Returns the total size of self on the stack, in bytes. Read more
source§

impl Eq for TimePoint

source§

impl StructuralEq for TimePoint

source§

impl StructuralPartialEq for TimePoint

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Az for T

source§

fn az<Dst>(self) -> Dstwhere T: Cast<Dst>,

Casts the value.
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Src, Dst> CastFrom<Src> for Dstwhere Src: Cast<Dst>,

source§

fn cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> CheckedAs for T

source§

fn checked_as<Dst>(self) -> Option<Dst>where T: CheckedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere Src: CheckedCast<Dst>,

source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
§

impl<Q, K> Comparable<K> for Qwhere Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
§

impl<T> Downcast<T> for T

§

fn downcast(&self) -> &T

source§

impl<T> DynClone for Twhere T: Clone,

source§

fn __clone_box(&self, _: Private) -> *mut ()

§

impl<T> EntityDataUi for Twhere T: DataUi,

§

fn entity_data_ui( &self, ctx: &mut ViewerContext<'_>, ui: &mut Ui, verbosity: UiVerbosity, _entity: &EntityPath, query: &LatestAtQuery )

If you need to lookup something in the data store, use the given query to do so.
§

impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<Src, Dst> LosslessTryInto<Dst> for Srcwhere Dst: LosslessTryFrom<Src>,

source§

fn lossless_try_into(self) -> Option<Dst>

Performs the conversion.
source§

impl<Src, Dst> LossyInto<Dst> for Srcwhere Dst: LossyFrom<Src>,

source§

fn lossy_into(self) -> Dst

Performs the conversion.
§

impl<T> NoneValue for Twhere T: Default,

§

type NoneType = T

§

fn null_value() -> T

The none-equivalent value.
source§

impl<T> OverflowingAs for T

source§

fn overflowing_as<Dst>(self) -> (Dst, bool)where T: OverflowingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere Src: OverflowingCast<Dst>,

source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
§

impl<T> Pointable for T

§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> SaturatingAs for T

source§

fn saturating_as<Dst>(self) -> Dstwhere T: SaturatingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere Src: SaturatingCast<Dst>,

source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> UnwrappedAs for T

source§

fn unwrapped_as<Dst>(self) -> Dstwhere T: UnwrappedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere Src: UnwrappedCast<Dst>,

source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
§

impl<T> Upcast<T> for T

§

fn upcast(&self) -> Option<&T>

§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
source§

impl<T> WrappingAs for T

source§

fn wrapping_as<Dst>(self) -> Dstwhere T: WrappingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere Src: WrappingCast<Dst>,

source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> DeserializeOwned for Twhere T: for<'de> Deserialize<'de>,

§

impl<T> SerializableAny for Twhere T: 'static + Any + Clone + Serialize + for<'a> Deserialize<'a> + Send + Sync,

§

impl<T> WasmNotSend for Twhere T: Send,

§

impl<T> WasmNotSync for Twhere T: Sync,