pub async fn route_from_self_by_name<C, V>(
name: &Name,
target: Arc<C>,
sources: Sources,
visitor: &mut V,
mapper: &mut dyn DebugRouteMapper,
) -> Result<CapabilitySource, RoutingError>where
C: ComponentInstanceInterface + 'static,
V: CapabilityVisitor + Clone + Send + Sync + 'static,
Expand description
Routes a capability from a capability name to its source by capabilities declarations, i.e. whatever capabilities that this component itself provides.
sources
defines what are the valid sources of the capability. See Sources
.
visitor
is invoked for each Capability
declaration if sources
permits.