fn handle_mlme_start_req(&mut self, req: fidl_mlme::StartRequest) -> Result<(), Error> {
        if self.bss.is_some() {
            info!("MLME-START.request: BSS already started");
            self.ctx
                .send_mlme_start_conf(fidl_mlme::StartResultCodes::BssAlreadyStartedOrJoined)?;
            return Ok(());
        }

        if req.bss_type != fidl_mlme::BssTypes::Infrastructure {
            info!("MLME-START.request: BSS type {:?} not supported", req.bss_type);
            self.ctx.send_mlme_start_conf(fidl_mlme::StartResultCodes::NotSupported)?;
            return Ok(());
        }

        self.bss.replace(InfraBss::new(
            &mut self.ctx,
            req.ssid.clone(),
            TimeUnit(req.beacon_period),
            CapabilityInfo(req.cap),
            req.rates,
            req.channel,
            req.rsne,
        )?);

        self.ctx.send_mlme_start_conf(fidl_mlme::StartResultCodes::Success)?;

        info!("MLME-START.request: OK");
        Ok(())
    }
/// Handles MLME-START.request (IEEE Std 802.11-2016, 6.3.11.2) from the SME.
Handles MLME-START.request  from the SME.
Handles MLME - START . request from the SME .
fn handle_mlme_start_req(&mut self, req: fidl_mlme::StartRequest) -> Result<(), Error> {
        if self.bss.is_some() {
            info!("MLME-START.request: BSS already started");
            self.ctx
                .send_mlme_start_conf(fidl_mlme::StartResultCodes::BssAlreadyStartedOrJoined)?;
            return Ok(());
        }
        if req.bss_type != fidl_mlme::BssTypes::Infrastructure {
            info!("MLME-START.request: BSS type {:?} not supported", req.bss_type);
            self.ctx.send_mlme_start_conf(fidl_mlme::StartResultCodes::NotSupported)?;
            return Ok(());
        }
        self.bss.replace(InfraBss::new(
            &mut self.ctx,
            req.ssid.clone(),
            TimeUnit(req.beacon_period),
            CapabilityInfo(req.cap),
            req.rates,
            req.channel,
            req.rsne,
        )?);
        self.ctx.send_mlme_start_conf(fidl_mlme::StartResultCodes::Success)?;
        info!("MLME-START.request: OK");
        Ok(())
    }
fn handle_mlme_start_req ( & mut self , req : fidl_mlme :: StartRequest ) -> Result < ( ) , Error > { if self . bss . is_some ( ) { info ! ( " " ) ; self . ctx . send_mlme_start_conf ( fidl_mlme :: StartResultCodes :: BssAlreadyStartedOrJoined ) ? ; return Ok ( ( ) ) ; } if req . bss_type != fidl_mlme :: BssTypes :: Infrastructure { info ! ( " " req bss_type ) ; self . ctx . send_mlme_start_conf ( fidl_mlme :: StartResultCodes :: NotSupported ) ? ; return Ok ( ( ) ) ; } self . bss . replace ( InfraBss :: new ( & mut self . ctx , req . ssid . clone ( ) , TimeUnit ( req . beacon_period ) , CapabilityInfo ( req . cap ) , req . rates , req . channel , req . rsne , ) ? ) ; self . ctx . send_mlme_start_conf ( fidl_mlme :: StartResultCodes :: Success ) ? ; info ! ( " " ) ; Ok ( ( ) ) }
Handles MLME-START.request (IEEE Std 802.11-2016, 6.3.11.2) from the SME.
Handles MLME - START . request ( IEEE Std 802 . 11 - 2016 6 . 3 . 11 . 2 ) from the SME .
&mut self
req
fidl_mlme::StartRequest