UNPKG

@tanislav000/bluez

Version:

Bluez5 D-Bus bindings for easy to use bluetooth access in Node.js

30 lines (29 loc) 1.11 kB
import { GattService } from "./gattService"; import { ProxyObject } from "dbus-next"; import { OrgBluezDevice1 } from "./dbus/Device1"; import { MediaControl } from "./mediaControl"; import { OrgBluezGattService1Props } from "./dbus/GattService1"; import { Bluez } from "./bluez"; export declare class Device extends OrgBluezDevice1 { private bluez; constructor(dbusObject: ProxyObject, bluez: Bluez); /** * Find a Gatt Service by UUID * @param uuid * @throws {DBusError} org.bluez.Error.DoesNotExist */ getGattService(uuid: string): Promise<GattService>; /** * Returns a list of known Gatt services * It returns key value pairs for each service. * The key is the object path and the value is a snapshot of the properties of the service. * To get the full service interface use `Bluez.getDbusObjectInterface(GattService, key)` */ listGattServices(): Promise<{ [key: string]: Partial<OrgBluezGattService1Props>; }>; /** * Returns the MediaControl interface if available */ getMediaControl(): MediaControl | null; }