fromFunctionPointer static method
ObjCBlock<Bool Function(Size, NSObject)>
fromFunctionPointer(
- Pointer<
NativeFunction< ptrBool Function(Size arg0, xpc_object_t arg1)> >
Creates a block from a C function pointer.
This block must be invoked by native code running on the same thread as the isolate that registered it. Invoking the block on the wrong thread will result in a crash.
Implementation
static objc.ObjCBlock<ffi.Bool Function(ffi.Size, objc.NSObject)>
fromFunctionPointer(
ffi.Pointer<
ffi.NativeFunction<ffi.Bool Function(ffi.Size arg0, xpc_object_t arg1)>
>
ptr,
) => objc.ObjCBlock<ffi.Bool Function(ffi.Size, objc.NSObject)>(
objc.newPointerBlock(
_ObjCBlock_bool_ffiSize_xpcobjectt_fnPtrCallable,
ptr.cast(),
),
retain: false,
release: true,
);