getSequenceNumber method

Future<int> getSequenceNumber(
  1. ProvisionedMeshNode node
)

A method to get the sequence number of a given mesh node

Implementation

Future<int> getSequenceNumber(ProvisionedMeshNode node) async {
  if (Platform.isIOS || Platform.isAndroid) {
    final result = await _methodChannel.invokeMethod<int>(
      'getSequenceNumberForAddress',
      {'address': await node.unicastAddress},
    );
    return result!;
  }
  throw Exception('Platform not supported');
}