getQueueStats method
Gets task queue statistics
Returns a Map with fields: pendingCount, activeCount, maxConcurrent, maxQueueSize
Implementation
@override
Future<Map<String, dynamic>> getQueueStats() async {
try {
final result = await methodChannel
.invokeMethod<Map<Object?, Object?>>('getQueueStats');
if (result == null) {
return {
'pendingCount': 0,
'activeCount': 0,
'maxConcurrent': 30,
'maxQueueSize': 10000,
};
}
return Map<String, dynamic>.from(result);
} on PlatformException catch (e) {
throw PlatformException(
code: e.code,
message: e.message,
details: e.details,
);
}
}