ServiceClient
A generic helper for binding to an Android Service via AIDL. Handles connection lifecycle, thread safety for initial binding, and automatic retry for common race conditions.
Parameters
stubFactory
A factory function to convert an IBinder to the interface type.
Type Parameters
T
The type of the AIDL interface.