Struct rerun::sdk::ComponentDescriptor
source · 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: ComponentName
Semantic 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
pub fn untagged(self) -> 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<&ComponentColumnDescriptor> for ComponentDescriptor
impl From<&ComponentColumnDescriptor> for ComponentDescriptor
source§fn from(descr: &ComponentColumnDescriptor) -> ComponentDescriptor
fn from(descr: &ComponentColumnDescriptor) -> ComponentDescriptor
source§impl From<ComponentColumnDescriptor> for ComponentDescriptor
impl From<ComponentColumnDescriptor> for ComponentDescriptor
source§fn from(descr: ComponentColumnDescriptor) -> ComponentDescriptor
fn from(descr: ComponentColumnDescriptor) -> 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§fn eq(&self, other: &ComponentDescriptor) -> bool
fn eq(&self, other: &ComponentDescriptor) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for ComponentDescriptor
impl PartialOrd for ComponentDescriptor
source§fn partial_cmp(&self, other: &ComponentDescriptor) -> Option<Ordering>
fn partial_cmp(&self, other: &ComponentDescriptor) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl SizeBytes for ComponentDescriptor
impl SizeBytes for ComponentDescriptor
source§fn heap_size_bytes(&self) -> u64
fn heap_size_bytes(&self) -> u64
self
on the heap, in bytes.source§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>
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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 moresource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request