1.传递
putParcelableArrayListExtra(
ConstantsUtil.BLUETOOTH_GATT_SERVICE_LIST,
mGattServiceList
)
val mGattServiceList = ArrayList<BluetoothGattService>()
2.接收
mBluetoothGattService = intent.getParcelableArrayListExtra<BluetoothGattService>(ConstantsUtil.BLUETOOTH_GATT_SERVICE_LIST) as ArrayList<BluetoothGattService>
private lateinit var mBluetoothGattService: ArrayList<BluetoothGattService>
该文讲述了在Android开发中如何使用putParcelableArrayListExtra方法将BluetoothGattService列表传递给Intent,然后在接收端如何通过getParcelableArrayListExtra获取并转换回ArrayList<BluetoothGattService>类型的数据。
2791

被折叠的 条评论
为什么被折叠?



