ObservingDevicePresenceRequest.Builder.SetUuid(ParcelUuid) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Set the ParcelUuid to be observed for device presence.
[Android.Runtime.Register("setUuid", "(Landroid/os/ParcelUuid;)Landroid/companion/ObservingDevicePresenceRequest$Builder;", "", ApiSince=36)]
public Android.Companion.ObservingDevicePresenceRequest.Builder SetUuid(Android.OS.ParcelUuid uuid);
[<Android.Runtime.Register("setUuid", "(Landroid/os/ParcelUuid;)Landroid/companion/ObservingDevicePresenceRequest$Builder;", "", ApiSince=36)>]
member this.SetUuid : Android.OS.ParcelUuid -> Android.Companion.ObservingDevicePresenceRequest.Builder
Parameters
- uuid
- ParcelUuid
The ParcelUuid for observing device presence. This value cannot be null.
Returns
This builder, with the UUID assigned.
- Attributes
Remarks
Set the ParcelUuid to be observed for device presence.
It does not require to create the association before calling this API. This only supports classic Bluetooth scan and caller must implement a single CompanionDeviceService which will be bound to and receive callbacks to CompanionDeviceService.onDevicePresenceEvent(DevicePresenceEvent).
The Uuid should be matching one of the ParcelUuid from BluetoothDevice.getUuids()
Calling apps must use either this API or setAssociationId(int), but not both.
Calling app must hold the AssociationRequest.DEVICE_PROFILE_AUTOMOTIVE_PROJECTION profile. Requires Manifest.permission.REQUEST_OBSERVE_DEVICE_UUID_PRESENCE and Manifest.permission.BLUETOOTH_CONNECT and Manifest.permission.BLUETOOTH_SCAN
Android reference for android.companion.ObservingDevicePresenceRequest.Builder.setUuid.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.