uninstallFilter method
Uninstall filter Uninstalls a filter with given id. Should always be called when watch is no longer needed. Additionally Filters timeout when they aren't requested with getFilterChanges for a period of time. Filter id Returns true if the filter was successfully uninstalled, otherwise false.
Implementation
Future<bool> uninstallFilter(int filterId) async {
if (filterId == null) {
throw ArgumentError.notNull("Moac::uninstallFilter - filterId");
}
final List params = [MoacUtilities.intToHex(filterId)];
final String method = MoacRpcMethods.uninstallFilter;
final res = await rpcClient.request(method, params);
if (res != null && res.containsKey(moacResultKey)) {
return res[moacResultKey];
}
_processError(method, res);
return null;
}