blob: 41222b16a93e34facd90974c6de400ae1228d710 [file] [edit]
// Copyright (c) 2025, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
// coverage:ignore-file
// AUTO GENERATED FILE, DO NOT EDIT.
//
// Generated by `package:ffigen`.
// ignore_for_file: type=lint, unused_import
import 'dart:ffi' as ffi;
import 'package:objective_c/objective_c.dart' as objc;
import 'package:ffi/ffi.dart' as pkg_ffi;
@ffi.Native<
ffi.Pointer<objc.ObjCBlockImpl> Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.DOBJC_Context>,
)
>(isLeaf: true)
external ffi.Pointer<objc.ObjCBlockImpl> _17w5sbb_wrapBlockingBlock_xtuoz7(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCBlockImpl> listnerBlock,
ffi.Pointer<objc.DOBJC_Context> context,
);
@ffi.Native<
ffi.Pointer<objc.ObjCBlockImpl> Function(ffi.Pointer<objc.ObjCBlockImpl>)
>(isLeaf: true)
external ffi.Pointer<objc.ObjCBlockImpl> _17w5sbb_wrapListenerBlock_xtuoz7(
ffi.Pointer<objc.ObjCBlockImpl> block,
);
/// Construction methods for `objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>`.
abstract final class ObjCBlock_ffiVoid_NSObject {
/// Returns a block that wraps the given raw block pointer.
static objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> fromPointer(
ffi.Pointer<objc.ObjCBlockImpl> pointer, {
bool retain = false,
bool release = false,
}) => objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>(
pointer,
retain: retain,
release: release,
);
/// 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.
static objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> fromFunctionPointer(
ffi.Pointer<
ffi.NativeFunction<
ffi.Void Function(ffi.Pointer<objc.ObjCObjectImpl> arg0)
>
>
ptr,
) => objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>(
objc.newPointerBlock(_fnPtrCallable, ptr.cast()),
retain: false,
release: true,
);
/// Creates a block from a Dart function.
///
/// 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.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC.
static objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> fromFunction(
void Function(objc.NSObject?) fn, {
bool keepIsolateAlive = true,
}) => objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>(
objc.newClosureBlock(
_closureCallable,
(ffi.Pointer<objc.ObjCObjectImpl> arg0) => fn(
arg0.address == 0
? null
: objc.NSObject.fromPointer(arg0, retain: true, release: true),
),
keepIsolateAlive,
),
retain: false,
release: true,
);
/// Creates a listener block from a Dart function.
///
/// This is based on FFI's NativeCallable.listener, and has the same
/// capabilities and limitations. This block can be invoked from any thread,
/// but only supports void functions, and is not run synchronously. See
/// NativeCallable.listener for more details.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC.
static objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> listener(
void Function(objc.NSObject?) fn, {
bool keepIsolateAlive = true,
}) {
final raw = objc.newClosureBlock(
_listenerCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) => fn(
arg0.address == 0
? null
: objc.NSObject.fromPointer(arg0, retain: false, release: true),
),
keepIsolateAlive,
);
final wrapper = _17w5sbb_wrapListenerBlock_xtuoz7(raw);
objc.objectRelease(raw.cast());
return objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>(
wrapper,
retain: false,
release: true,
);
}
/// Creates a blocking block from a Dart function.
///
/// This callback can be invoked from any native thread, and will block the
/// caller until the callback is handled by the Dart isolate that created
/// the block. Async functions are not supported.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC. If the owner isolate
/// has shut down, and the block is invoked by native code, it may block
/// indefinitely, or have other undefined behavior.
static objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> blocking(
void Function(objc.NSObject?) fn, {
bool keepIsolateAlive = true,
}) {
final raw = objc.newClosureBlock(
_blockingCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) => fn(
arg0.address == 0
? null
: objc.NSObject.fromPointer(arg0, retain: false, release: true),
),
keepIsolateAlive,
);
final rawListener = objc.newClosureBlock(
_blockingListenerCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) => fn(
arg0.address == 0
? null
: objc.NSObject.fromPointer(arg0, retain: false, release: true),
),
keepIsolateAlive,
);
final wrapper = _17w5sbb_wrapBlockingBlock_xtuoz7(
raw,
rawListener,
objc.objCContext,
);
objc.objectRelease(raw.cast());
objc.objectRelease(rawListener.cast());
return objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>(
wrapper,
retain: false,
release: true,
);
}
static void _listenerTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) {
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
objc.objectRelease(block.cast());
}
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_listenerCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.listener(_listenerTrampoline)
..keepIsolateAlive = false;
static void _blockingTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<ffi.Void> waiter,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) {
try {
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
} catch (e) {
} finally {
objc.signalWaiter(waiter);
objc.objectRelease(block.cast());
}
}
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_blockingCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.isolateLocal(_blockingTrampoline)
..keepIsolateAlive = false;
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_blockingListenerCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.listener(_blockingTrampoline)
..keepIsolateAlive = false;
static void _fnPtrTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) => block.ref.target
.cast<
ffi.NativeFunction<
ffi.Void Function(ffi.Pointer<objc.ObjCObjectImpl> arg0)
>
>()
.asFunction<void Function(ffi.Pointer<objc.ObjCObjectImpl>)>()(arg0);
static ffi.Pointer<ffi.Void> _fnPtrCallable =
ffi.Pointer.fromFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>(_fnPtrTrampoline)
.cast();
static void _closureTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) =>
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
static ffi.Pointer<ffi.Void> _closureCallable =
ffi.Pointer.fromFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>(_closureTrampoline)
.cast();
}
/// Call operator for `objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>`.
extension ObjCBlock_ffiVoid_NSObject$CallExtension
on objc.ObjCBlock<ffi.Void Function(objc.NSObject?)> {
void call(objc.NSObject? arg0) => ref.pointer.ref.invoke
.cast<
ffi.NativeFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
)
>
>()
.asFunction<
void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>()(ref.pointer, arg0?.ref.pointer ?? ffi.nullptr);
}
/// Construction methods for `objc.ObjCBlock<ffi.Void Function(objc.NSString)>`.
abstract final class ObjCBlock_ffiVoid_NSString {
/// Returns a block that wraps the given raw block pointer.
static objc.ObjCBlock<ffi.Void Function(objc.NSString)> fromPointer(
ffi.Pointer<objc.ObjCBlockImpl> pointer, {
bool retain = false,
bool release = false,
}) => objc.ObjCBlock<ffi.Void Function(objc.NSString)>(
pointer,
retain: retain,
release: release,
);
/// 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.
static objc.ObjCBlock<ffi.Void Function(objc.NSString)> fromFunctionPointer(
ffi.Pointer<
ffi.NativeFunction<
ffi.Void Function(ffi.Pointer<objc.ObjCObjectImpl> arg0)
>
>
ptr,
) => objc.ObjCBlock<ffi.Void Function(objc.NSString)>(
objc.newPointerBlock(_fnPtrCallable, ptr.cast()),
retain: false,
release: true,
);
/// Creates a block from a Dart function.
///
/// 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.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC.
static objc.ObjCBlock<ffi.Void Function(objc.NSString)> fromFunction(
void Function(objc.NSString) fn, {
bool keepIsolateAlive = true,
}) => objc.ObjCBlock<ffi.Void Function(objc.NSString)>(
objc.newClosureBlock(
_closureCallable,
(ffi.Pointer<objc.ObjCObjectImpl> arg0) =>
fn(objc.NSString.fromPointer(arg0, retain: true, release: true)),
keepIsolateAlive,
),
retain: false,
release: true,
);
/// Creates a listener block from a Dart function.
///
/// This is based on FFI's NativeCallable.listener, and has the same
/// capabilities and limitations. This block can be invoked from any thread,
/// but only supports void functions, and is not run synchronously. See
/// NativeCallable.listener for more details.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC.
static objc.ObjCBlock<ffi.Void Function(objc.NSString)> listener(
void Function(objc.NSString) fn, {
bool keepIsolateAlive = true,
}) {
final raw = objc.newClosureBlock(
_listenerCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) =>
fn(objc.NSString.fromPointer(arg0, retain: false, release: true)),
keepIsolateAlive,
);
final wrapper = _17w5sbb_wrapListenerBlock_xtuoz7(raw);
objc.objectRelease(raw.cast());
return objc.ObjCBlock<ffi.Void Function(objc.NSString)>(
wrapper,
retain: false,
release: true,
);
}
/// Creates a blocking block from a Dart function.
///
/// This callback can be invoked from any native thread, and will block the
/// caller until the callback is handled by the Dart isolate that created
/// the block. Async functions are not supported.
///
/// If `keepIsolateAlive` is true, this block will keep this isolate alive
/// until it is garbage collected by both Dart and ObjC. If the owner isolate
/// has shut down, and the block is invoked by native code, it may block
/// indefinitely, or have other undefined behavior.
static objc.ObjCBlock<ffi.Void Function(objc.NSString)> blocking(
void Function(objc.NSString) fn, {
bool keepIsolateAlive = true,
}) {
final raw = objc.newClosureBlock(
_blockingCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) =>
fn(objc.NSString.fromPointer(arg0, retain: false, release: true)),
keepIsolateAlive,
);
final rawListener = objc.newClosureBlock(
_blockingListenerCallable.nativeFunction.cast(),
(ffi.Pointer<objc.ObjCObjectImpl> arg0) =>
fn(objc.NSString.fromPointer(arg0, retain: false, release: true)),
keepIsolateAlive,
);
final wrapper = _17w5sbb_wrapBlockingBlock_xtuoz7(
raw,
rawListener,
objc.objCContext,
);
objc.objectRelease(raw.cast());
objc.objectRelease(rawListener.cast());
return objc.ObjCBlock<ffi.Void Function(objc.NSString)>(
wrapper,
retain: false,
release: true,
);
}
static void _listenerTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) {
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
objc.objectRelease(block.cast());
}
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_listenerCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.listener(_listenerTrampoline)
..keepIsolateAlive = false;
static void _blockingTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<ffi.Void> waiter,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) {
try {
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
} catch (e) {
} finally {
objc.signalWaiter(waiter);
objc.objectRelease(block.cast());
}
}
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_blockingCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.isolateLocal(_blockingTrampoline)
..keepIsolateAlive = false;
static ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
_blockingListenerCallable =
ffi.NativeCallable<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<ffi.Void>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>.listener(_blockingTrampoline)
..keepIsolateAlive = false;
static void _fnPtrTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) => block.ref.target
.cast<
ffi.NativeFunction<
ffi.Void Function(ffi.Pointer<objc.ObjCObjectImpl> arg0)
>
>()
.asFunction<void Function(ffi.Pointer<objc.ObjCObjectImpl>)>()(arg0);
static ffi.Pointer<ffi.Void> _fnPtrCallable =
ffi.Pointer.fromFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>(_fnPtrTrampoline)
.cast();
static void _closureTrampoline(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
) =>
(objc.getBlockClosure(block)
as void Function(ffi.Pointer<objc.ObjCObjectImpl>))(arg0);
static ffi.Pointer<ffi.Void> _closureCallable =
ffi.Pointer.fromFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>(_closureTrampoline)
.cast();
}
/// Call operator for `objc.ObjCBlock<ffi.Void Function(objc.NSString)>`.
extension ObjCBlock_ffiVoid_NSString$CallExtension
on objc.ObjCBlock<ffi.Void Function(objc.NSString)> {
void call(objc.NSString arg0) => ref.pointer.ref.invoke
.cast<
ffi.NativeFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCBlockImpl> block,
ffi.Pointer<objc.ObjCObjectImpl> arg0,
)
>
>()
.asFunction<
void Function(
ffi.Pointer<objc.ObjCBlockImpl>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>()(ref.pointer, arg0.ref.pointer);
}
/// TestMessageService
extension type TestMessageService._(objc.ObjCObject object$)
implements objc.ObjCObject, objc.NSObject {
/// Constructs a [TestMessageService] that points to the same underlying object as [other].
TestMessageService.as(objc.ObjCObject other) : object$ = other {
assert(isA(object$));
}
/// Constructs a [TestMessageService] that wraps the given raw object pointer.
TestMessageService.fromPointer(
ffi.Pointer<objc.ObjCObjectImpl> other, {
bool retain = false,
bool release = false,
}) : object$ = objc.ObjCObject(other, retain: retain, release: release) {
assert(isA(object$));
}
/// Returns whether [obj] is an instance of [TestMessageService].
static bool isA(objc.ObjCObject? obj) => obj == null
? false
: _objc_msgSend_19nvye5(
obj.ref.pointer,
_sel_isKindOfClass_,
_class_TestMessageService,
);
/// alloc
static TestMessageService alloc() {
final $ret = _objc_msgSend_151sglz(_class_TestMessageService, _sel_alloc);
return TestMessageService.fromPointer($ret, retain: false, release: true);
}
/// allocWithZone:
static TestMessageService allocWithZone(ffi.Pointer<objc.NSZone> zone) {
final $ret = _objc_msgSend_1cwp428(
_class_TestMessageService,
_sel_allocWithZone_,
zone,
);
return TestMessageService.fromPointer($ret, retain: false, release: true);
}
/// echoAsyncObjectWithAnObject:completionHandler:
static void echoAsyncObjectWithAnObject(
objc.NSObject anObject, {
required objc.ObjCBlock<ffi.Void Function(objc.NSObject?)>
completionHandler,
}) {
_objc_msgSend_o762yo(
_class_TestMessageService,
_sel_echoAsyncObjectWithAnObject_completionHandler_,
anObject.ref.pointer,
completionHandler.ref.pointer,
);
}
/// fetchGreetingAsyncWithCompletionHandler:
static void fetchGreetingAsyncWithCompletionHandler(
objc.ObjCBlock<ffi.Void Function(objc.NSString)> completionHandler,
) {
_objc_msgSend_f167m6(
_class_TestMessageService,
_sel_fetchGreetingAsyncWithCompletionHandler_,
completionHandler.ref.pointer,
);
}
/// fetchGreetingWithCompletion:
static void fetchGreetingWithCompletion(
objc.ObjCBlock<ffi.Void Function(objc.NSString)> completion,
) {
_objc_msgSend_f167m6(
_class_TestMessageService,
_sel_fetchGreetingWithCompletion_,
completion.ref.pointer,
);
}
/// new
static TestMessageService new$() {
final $ret = _objc_msgSend_151sglz(_class_TestMessageService, _sel_new);
return TestMessageService.fromPointer($ret, retain: false, release: true);
}
/// Returns a new instance of TestMessageService constructed with the default `new` method.
TestMessageService() : this.as(new$().object$);
}
extension TestMessageService$Methods on TestMessageService {
/// init
TestMessageService init() {
objc.checkOsVersionInternal(
'TestMessageService.init',
iOS: (false, (2, 0, 0)),
macOS: (false, (10, 0, 0)),
);
final $ret = _objc_msgSend_151sglz(
object$.ref.retainAndReturnPointer(),
_sel_init,
);
return TestMessageService.fromPointer($ret, retain: false, release: true);
}
}
late final _class_TestMessageService = objc.getClass(
"callbacks.TestMessageService",
);
final _objc_msgSend_151sglz = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer<objc.ObjCObjectImpl> Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
)
>
>()
.asFunction<
ffi.Pointer<objc.ObjCObjectImpl> Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
)
>();
final _objc_msgSend_19nvye5 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Bool Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>
>()
.asFunction<
bool Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCObjectImpl>,
)
>();
final _objc_msgSend_1cwp428 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Pointer<objc.ObjCObjectImpl> Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.NSZone>,
)
>
>()
.asFunction<
ffi.Pointer<objc.ObjCObjectImpl> Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.NSZone>,
)
>();
final _objc_msgSend_f167m6 = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCBlockImpl>,
)
>
>()
.asFunction<
void Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCBlockImpl>,
)
>();
final _objc_msgSend_o762yo = objc.msgSendPointer
.cast<
ffi.NativeFunction<
ffi.Void Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCBlockImpl>,
)
>
>()
.asFunction<
void Function(
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCSelector>,
ffi.Pointer<objc.ObjCObjectImpl>,
ffi.Pointer<objc.ObjCBlockImpl>,
)
>();
late final _sel_alloc = objc.registerName("alloc");
late final _sel_allocWithZone_ = objc.registerName("allocWithZone:");
late final _sel_echoAsyncObjectWithAnObject_completionHandler_ = objc
.registerName("echoAsyncObjectWithAnObject:completionHandler:");
late final _sel_fetchGreetingAsyncWithCompletionHandler_ = objc.registerName(
"fetchGreetingAsyncWithCompletionHandler:",
);
late final _sel_fetchGreetingWithCompletion_ = objc.registerName(
"fetchGreetingWithCompletion:",
);
late final _sel_init = objc.registerName("init");
late final _sel_isKindOfClass_ = objc.registerName("isKindOfClass:");
late final _sel_new = objc.registerName("new");
typedef instancetype = ffi.Pointer<objc.ObjCObjectImpl>;
typedef Dartinstancetype = objc.ObjCObject;