binder_ndk_sys

Function AStatus_fromStatus

Source
pub unsafe extern "C" fn AStatus_fromStatus(
    status: binder_status_t,
) -> *mut AStatus
Expand description

New status with binder_status_t. This is typically for low level failures when a binder_status_t is returned by an API on AIBinder or AParcel, and that is to be returned from a method returning an AStatus instance. This is the least preferable way to return errors. Prefer exceptions (particularly service-specific errors) when possible.

Available since API level 29.

\param status a low-level error to associate with this status object.

\return a newly constructed status object that the caller owns.