Function binder_ndk_sys::AServiceManager_waitForService

source ยท
pub unsafe extern "C" fn AServiceManager_waitForService(
    instance: *const c_char,
) -> *mut AIBinder
Expand description

Gets a binder object with this specific instance name. Efficiently waits for the service. If the service is not ever registered, it will wait indefinitely. Requires the threadpool to be started in the service. This also implicitly calls AIBinder_incStrong (so the caller of this function is responsible for calling AIBinder_decStrong).

WARNING: when using this API across an APEX boundary, do not use with unstable AIDL services. TODO(b/139325195)

\param instance identifier of the service used to lookup the service.

\return service if registered, null if not.