init method

  1. @override
  2. @nonVirtual
Future<void> init()
override

Implementation

@override
@nonVirtual
Future<void> init() async {
  if (_initCompleter == null) {
    _initCompleter = Completer();

    initOnce().then((final _) {
      _initCompleter!.complete();
      _initialized = true;
    }).catchError((final e) {
      _initCompleter!.completeError(e);
    });
  }

  return _initCompleter!.future;
}