typedArrayBytesDeallocatorCallbackDartToNativeConverter function
NativeCallable<JSTypedArrayBytesDeallocator_>
typedArrayBytesDeallocatorCallbackDartToNativeConverter(
- JSTypedArrayBytesDeallocator? convertToType,
- int len
Implementation
NativeCallable<JSTypedArrayBytesDeallocator_>
typedArrayBytesDeallocatorCallbackDartToNativeConverter(
JSTypedArrayBytesDeallocator? convertToType,
int len,
) {
return NativeCallable.listener((
Pointer<Void> bytes,
Pointer<Void> deallocatorContext,
) {
return convertToType?.call(
bytes.toUint8List(len),
deallocatorContext.toUint8List(len),
);
});
}