callHashSetMethod<E> method
async call native method which return hash set
Implementation
Future<Set<E>?> callHashSetMethod<E>(String methodName,
{List? args,
List<String>? assignedSignature,
Thread thread = Thread.mainThread}) async {
return callMethod(methodName, 'Ljava/util/HashSet;',
args: args, assignedSignature: assignedSignature, thread: thread)
.then((value) {
final ptr = (value as JObject).pointer;
if (ptr == nullptr) {
return null;
}
return JHashSet<E>.fromPointer(ptr).raw.cast<E>();
});
}