async fn new_netstack_and_device<N, E, S, T>(
        &self,
        name: T,
    ) -> Result<(netemul::TestRealm<'_>, S::Proxy, netemul::TestEndpoint<'_>)>
    where
        N: Netstack,
        E: netemul::Endpoint,
        S: fidl::endpoints::ServiceMarker + fidl::endpoints::DiscoverableService,
        T: Into<String> + Copy + Send,
    {
        let (realm, stack) = self.new_netstack::<N, S, _>(name)?;
        let endpoint =
            self.create_endpoint::<E, _>(name).await.context("failed to create endpoint")?;
        Ok((realm, stack, endpoint))
    }
/// Helper function to create a new Netstack realm and a new unattached
/// endpoint.
Helper function to create a new Netstack realm and a new unattached
endpoint.
Helper function to create a new Netstack realm and a new unattached endpoint .
async fn new_netstack_and_device<N, E, S, T>(
        &self,
        name: T,
    ) -> Result<(netemul::TestRealm<'_>, S::Proxy, netemul::TestEndpoint<'_>)>
    where
        N: Netstack,
        E: netemul::Endpoint,
        S: fidl::endpoints::ServiceMarker + fidl::endpoints::DiscoverableService,
        T: Into<String> + Copy + Send,
    {
        let (realm, stack) = self.new_netstack::<N, S, _>(name)?;
        let endpoint =
            self.create_endpoint::<E, _>(name).await.context("failed to create endpoint")?;
        Ok((realm, stack, endpoint))
    }
async fn new_netstack_and_device < N , E , S , T > ( & self , name : T , ) -> Result < ( netemul :: TestRealm < ' _ > , S :: Proxy , netemul :: TestEndpoint < ' _ > ) > where N : Netstack , E : netemul :: Endpoint , S : fidl :: endpoints :: ServiceMarker + fidl :: endpoints :: DiscoverableService , T : Into < String > + Copy + Send , { let ( realm , stack ) = self . new_netstack :: < N , S , _ > ( name ) ? ; let endpoint = self . create_endpoint :: < E , _ > ( name ) . await . context ( " " ) ? ; Ok ( ( realm , stack , endpoint ) ) }
Helper function to create a new Netstack realm and a new unattached
endpoint.
Helper function to create a new Netstack realm and a new unattached endpoint .
&self
name
T
&self
name
T