nativeFunction property

Pointer<NativeFunction<C>> get nativeFunction

Implementation

Pointer<NativeFunction<C>> get nativeFunction {
  // NOTE: we initialize in getter, because constructor
  //       initialization made the app hang on exit,
  //       because callbacks were not disposed() properly
  if (!_initialized) {
    _initialized = true;
    _callable = initializer();
  }
  assert(!_isDisposed, '$runtimeType: has been disposed');
  return _callable.nativeFunction;
}