pub struct ComponentDescriptor {
pub archetype_name: Option<ArchetypeName>,
pub archetype_field_name: Option<ArchetypeFieldName>,
pub component_name: ComponentName,
}Expand description
A ComponentDescriptor fully describes the semantics of a column of data.
Every component is uniquely identified by its ComponentDescriptor.
Fields§
§archetype_name: Option<ArchetypeName>Optional name of the Archetype associated with this data.
None if the data wasn’t logged through an archetype.
Example: rerun.archetypes.Points3D.
archetype_field_name: Option<ArchetypeFieldName>Optional name of the field within Archetype associated with this data.
None if the data wasn’t logged through an archetype.
Example: positions.
component_name: ComponentNameSemantic name associated with this data.
This is fully implied by archetype_name and archetype_field, but
included for semantic convenience.
Example: rerun.components.Position3D.
Implementations§
Source§impl ComponentDescriptor
impl ComponentDescriptor
Sourcepub fn full_name(&self) -> String
pub fn full_name(&self) -> String
Returns the fully-qualified name, e.g. rerun.archetypes.Points3D:rerun.components.Position3D#positions.
This is the default Display implementation for ComponentDescriptor.
Sourcepub fn short_name(&self) -> String
pub fn short_name(&self) -> String
Returns the unqualified name, e.g. Points3D:Position3D#positions.
Source§impl ComponentDescriptor
impl ComponentDescriptor
pub fn new(component_name: impl Into<ComponentName>) -> ComponentDescriptor
Sourcepub fn with_archetype_name(
self,
archetype_name: ArchetypeName,
) -> ComponentDescriptor
pub fn with_archetype_name( self, archetype_name: ArchetypeName, ) -> ComponentDescriptor
Unconditionally sets Self::archetype_name to the given one.
Sourcepub fn with_archetype_field_name(
self,
archetype_field_name: ArchetypeFieldName,
) -> ComponentDescriptor
pub fn with_archetype_field_name( self, archetype_field_name: ArchetypeFieldName, ) -> ComponentDescriptor
Unconditionally sets Self::archetype_field_name to the given one.
Sourcepub fn or_with_archetype_name(
self,
archetype_name: impl Fn() -> ArchetypeName,
) -> ComponentDescriptor
pub fn or_with_archetype_name( self, archetype_name: impl Fn() -> ArchetypeName, ) -> ComponentDescriptor
Sets Self::archetype_name to the given one iff it’s not already set.
Sourcepub fn or_with_archetype_field_name(
self,
archetype_field_name: impl FnOnce() -> ArchetypeFieldName,
) -> ComponentDescriptor
pub fn or_with_archetype_field_name( self, archetype_field_name: impl FnOnce() -> ArchetypeFieldName, ) -> ComponentDescriptor
Sets Self::archetype_field_name to the given one iff it’s not already set.
Trait Implementations§
Source§impl Clone for ComponentDescriptor
impl Clone for ComponentDescriptor
Source§fn clone(&self) -> ComponentDescriptor
fn clone(&self) -> ComponentDescriptor
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ComponentDescriptor
impl Debug for ComponentDescriptor
Source§impl Display for ComponentDescriptor
impl Display for ComponentDescriptor
Source§impl From<Field> for ComponentDescriptor
impl From<Field> for ComponentDescriptor
Source§fn from(field: Field) -> ComponentDescriptor
fn from(field: Field) -> ComponentDescriptor
Source§impl Hash for ComponentDescriptor
impl Hash for ComponentDescriptor
Source§impl Ord for ComponentDescriptor
impl Ord for ComponentDescriptor
Source§fn cmp(&self, other: &ComponentDescriptor) -> Ordering
fn cmp(&self, other: &ComponentDescriptor) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for ComponentDescriptor
impl PartialEq for ComponentDescriptor
Source§impl PartialOrd for ComponentDescriptor
impl PartialOrd for ComponentDescriptor
Source§impl SizeBytes for ComponentDescriptor
impl SizeBytes for ComponentDescriptor
Source§fn heap_size_bytes(&self) -> u64
fn heap_size_bytes(&self) -> u64
self uses on the heap. Read moreSource§fn total_size_bytes(&self) -> u64
fn total_size_bytes(&self) -> u64
self in bytes, accounting for both stack and heap space.Source§fn stack_size_bytes(&self) -> u64
fn stack_size_bytes(&self) -> u64
self on the stack, in bytes. Read moreimpl Eq for ComponentDescriptor
impl IsEnabled for ComponentDescriptor
impl StructuralPartialEq for ComponentDescriptor
Auto Trait Implementations§
impl Freeze for ComponentDescriptor
impl RefUnwindSafe for ComponentDescriptor
impl Send for ComponentDescriptor
impl Sync for ComponentDescriptor
impl Unpin for ComponentDescriptor
impl UnwindSafe for ComponentDescriptor
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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