public static interface BluetoothProfile.ServiceListener
| android.bluetooth.BluetoothProfile.ServiceListener |
用于在BluetoothProfile IPC客户端连接或断开服务时通知其的接口。
公共方法(Public methods) |
|
|---|---|
abstract void |
onServiceConnected(int profile, BluetoothProfile proxy) 当代理对象已连接到服务时被调用以通知客户端。 |
abstract void |
onServiceDisconnected(int profile) 被调用来通知客户端此代理对象已与服务断开连接。 |
void onServiceConnected (int profile,
BluetoothProfile proxy)
当代理对象已连接到服务时被调用以通知客户端。
| 参数(Parameters) | |
|---|---|
profile |
int: - One of HEALTH, HEADSET or A2DP |
proxy |
BluetoothProfile: - One of BluetoothHealth, BluetoothHeadset or BluetoothA2dp |
void onServiceDisconnected (int profile)
被调用来通知客户端此代理对象已与服务断开连接。
| 参数(Parameters) | |
|---|---|
profile |
int: - One of HEALTH, HEADSET or A2DP |