/// If the source of a protocol capability is a component instance, checks that that
/// instance is executable.
///
/// If the source is a capability, checks that the protocol is the `StorageAdmin`
/// protocol and that the source is a valid storage capability.
If the source of a protocol capability is a component instance, checks that that
instance is executable.

If the source is a capability, checks that the protocol is the `StorageAdmin`
protocol and that the source is a valid storage capability.
If the source of a protocol capability is a component instance checks that that instance is executable . If the source is a capability checks that the protocol is the ` StorageAdmin ` protocol and that the source is a valid storage capability .
async fn check_protocol_source(
        &self,
        source: &CapabilitySourceInterface<ComponentInstanceForAnalyzer>,
    ) -> Result<(), AnalyzerModelError> {
        match source {
            CapabilitySourceInterface::Component { component: weak, .. } => {
                self.check_executable(&weak.upgrade()?).await
            }
            CapabilitySourceInterface::Namespace { .. } => Ok(()),
            CapabilitySourceInterface::Capability { source_capability, component: weak } => {
                self.check_protocol_capability_source(&weak.upgrade()?, &source_capability).await
            }
            CapabilitySourceInterface::Builtin { .. } => Ok(()),
            CapabilitySourceInterface::Framework { .. } => Ok(()),
            _ => unimplemented![],
        }
    }
async fn check_protocol_source ( & self , source : & CapabilitySourceInterface < ComponentInstanceForAnalyzer > , ) -> Result < ( ) , AnalyzerModelError > { match source { CapabilitySourceInterface :: Component { component : weak , .. } => { self . check_executable ( & weak . upgrade ( ) ? ) . await } CapabilitySourceInterface :: Namespace { .. } => Ok ( ( ) ) , CapabilitySourceInterface :: Capability { source_capability , component : weak } => { self . check_protocol_capability_source ( & weak . upgrade ( ) ? , & source_capability ) . await } CapabilitySourceInterface :: Builtin { .. } => Ok ( ( ) ) , CapabilitySourceInterface :: Framework { .. } => Ok ( ( ) ) , _ => unimplemented ! [ ] , } }
If the source of a protocol capability is a component instance, checks that that
instance is executable.
If the source of a protocol capability is a component instance checks that that instance is executable .
&self
source
&CapabilitySourceInterface<ComponentInstanceForAnalyzer>