Table of Contents

Class BluetoothDevice

Namespace
CSharpToJavaScript.APIs.JS
Assembly
CSharpToJavaScript.dll
NOTE
Experimental
The BluetoothDevice interface of the Web Bluetooth API represents a Bluetooth device inside a particular script execution
environment.
[Value("BluetoothDevice")]
public class BluetoothDevice : EventTarget, BluetoothDeviceEventHandlers, CharacteristicEventHandlers, ServiceEventHandlers
Inheritance
BluetoothDevice
Implements
Inherited Members

Remarks

Constructors

BluetoothDevice()

public BluetoothDevice()

Properties

Gatt

NOTE
Experimental
The
BluetoothDevice.gatt read-only property returns
a reference to the device's BluetoothRemoteGATTServer.
[Value("gatt")]
public BluetoothRemoteGATTServer? Gatt { get; }

Property Value

BluetoothRemoteGATTServer

A reference to the device's BluetoothRemoteGATTServer.

Remarks

Id

NOTE
Experimental
The BluetoothDevice.id read-only property returns a
string that uniquely identifies a device.
[Value("id")]
public string Id { get; }

Property Value

string

A string.

Remarks

Name

NOTE
Experimental
The BluetoothDevice.name read-only property returns a
string that provides a human-readable name for the device.
[Value("name")]
public string? Name { get; }

Property Value

string

A string.

Remarks

WatchingAdvertisements

[Value("watchingAdvertisements")]
public bool WatchingAdvertisements { get; }

Property Value

bool

Methods

Forget()

[Value("forget")]
public Task<GlobalObject.Undefined> Forget()

Returns

Task<GlobalObject.Undefined>

WatchAdvertisements(WatchAdvertisementsOptions)

[Value("watchAdvertisements")]
public Task<GlobalObject.Undefined> WatchAdvertisements(WatchAdvertisementsOptions options = null)

Parameters

options WatchAdvertisementsOptions

Returns

Task<GlobalObject.Undefined>