How to add multiple permissions and properties to a characteristic

烂漫一生 提交于 2019-12-12 13:11:51

问题


There is only one constructor for type BluetoothGattCharacteristic

BluetoothGattCharacteristic(UUID uuid, int properties, int permissions)

Does the constructor take exactly one property and one permission?

For example, I want a characteristic to be both readable and writable. Doesn't this means I need two sets of permission-property pairs?

PERMISSION_READ
PROPERTY_READ

and

PERMISSION_WRITE
PROPERTY_WRITE

But according to the constructor, I can only set one permission and property when I need two of each right? So how do I add multiple permissions and properties to a characteristic?

来源:https://stackoverflow.com/questions/47341064/how-to-add-multiple-permissions-and-properties-to-a-characteristic

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!