pub struct ComponentInstance { /* private fields */ }Expand description
One resolved component instance in the canonical robot.
Implementations§
Source§impl ComponentInstance
impl ComponentInstance
pub const fn id(&self) -> &ComponentInstanceId
pub const fn component_type(&self) -> &ComponentTypeId
Sourcepub const fn mount_link(&self) -> &LinkId
pub const fn mount_link(&self) -> &LinkId
The robot link this instance is rigidly mounted on.
Sourcepub const fn roles(&self) -> &BTreeMap<CapabilityId, BTreeSet<CapabilityRole>>
pub const fn roles(&self) -> &BTreeMap<CapabilityId, BTreeSet<CapabilityRole>>
Authored role assignments, ordered by capability and role.
Sourcepub fn has_role(&self, capability: &CapabilityId, role: CapabilityRole) -> bool
pub fn has_role(&self, capability: &CapabilityId, role: CapabilityRole) -> bool
Whether this instance assigns role to the named capability.
Trait Implementations§
Source§impl Clone for ComponentInstance
impl Clone for ComponentInstance
Source§fn clone(&self) -> ComponentInstance
fn clone(&self) -> ComponentInstance
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ComponentInstance
impl Debug for ComponentInstance
Source§impl DescribeWire for ComponentInstance
impl DescribeWire for ComponentInstance
Source§fn wire_schema() -> WireSchema
fn wire_schema() -> WireSchema
The shape a value of this type puts on the wire.
Source§impl<'de> Deserialize<'de> for ComponentInstance
impl<'de> Deserialize<'de> for ComponentInstance
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ComponentInstance
impl RefUnwindSafe for ComponentInstance
impl Send for ComponentInstance
impl Sync for ComponentInstance
impl Unpin for ComponentInstance
impl UnsafeUnpin for ComponentInstance
impl UnwindSafe for ComponentInstance
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
Mutably borrows from an owned value. Read more