pub fn run_services(
    sender: mpsc::Sender<ServiceRequest>,
) -> Result<impl Future<Output = Result<(), Error>>, Error> {
    let mut fs = ServiceFs::new();
    let sender_avrcp = sender.clone();
    let sender_test = sender.clone();
    fs.dir("svc")
        .add_fidl_service_at(PeerManagerExtMarker::NAME, move |stream| {
            spawn_test_avrcp_client(stream, sender_test.clone());
        })
        .add_fidl_service_at(PeerManagerMarker::NAME, move |stream| {
            spawn_avrcp_client(stream, sender_avrcp.clone());
        });
    fs.take_and_serve_directory_handle()?;
    fx_log_info!("Running fidl service");
    Ok(fs.collect::<()>().map(|_| Err(format_err!("FIDL service listener returned"))))
}
/// Sets up public FIDL services and client handlers.
Sets up public FIDL services and client handlers.
Sets up public FIDL services and client handlers .
pub fn run_services(
    sender: mpsc::Sender<ServiceRequest>,
) -> Result<impl Future<Output = Result<(), Error>>, Error> {
    let mut fs = ServiceFs::new();
    let sender_avrcp = sender.clone();
    let sender_test = sender.clone();
    fs.dir("svc")
        .add_fidl_service_at(PeerManagerExtMarker::NAME, move |stream| {
            spawn_test_avrcp_client(stream, sender_test.clone());
        })
        .add_fidl_service_at(PeerManagerMarker::NAME, move |stream| {
            spawn_avrcp_client(stream, sender_avrcp.clone());
        });
    fs.take_and_serve_directory_handle()?;
    fx_log_info!("Running fidl service");
    Ok(fs.collect::<()>().map(|_| Err(format_err!("FIDL service listener returned"))))
}
pub fn run_services ( sender : mpsc :: Sender < ServiceRequest > , ) -> Result < impl Future < Output = Result < ( ) , Error > > , Error > { let mut fs = ServiceFs :: new ( ) ; let sender_avrcp = sender . clone ( ) ; let sender_test = sender . clone ( ) ; fs . dir ( " " ) . add_fidl_service_at ( PeerManagerExtMarker :: NAME , move | stream | { spawn_test_avrcp_client ( stream , sender_test . clone ( ) ) ; } ) . add_fidl_service_at ( PeerManagerMarker :: NAME , move | stream | { spawn_avrcp_client ( stream , sender_avrcp . clone ( ) ) ; } ) ; fs . take_and_serve_directory_handle ( ) ? ; fx_log_info ! ( " " ) ; Ok ( fs . collect :: < ( ) > ( ) . map ( | _ | Err ( format_err ! ( " " ) ) ) ) }
Sets up public FIDL services and client handlers.
Sets up public FIDL services and client handlers .
sender
mpsc::Sender<ServiceRequest>
sender
mpsc::Sender<ServiceRequest>