acquireNotify method

Acquire a RawSocket for receiving notifications from this characterisitic. To release the lock close the returned socket.

Implementation

Future<BlueZGattAcquireNotifyResult> acquireNotify() async {
  var options = <String, DBusValue>{};
  var result = await _object.callMethod(_gattCharacteristicInterfaceName,
      'AcquireNotify', [DBusDict.stringVariant(options)],
      replySignature: DBusSignature('hq'));
  var handle = result.values[0].asUnixFd();
  var mtu = result.values[1].asUint16();
  return BlueZGattAcquireNotifyResult(handle.toRawSocket(), mtu);
}