initialize method

void initialize()

Implementation

void initialize() async {
  _status = IsoBridgeStatus.execwait;
  var actionInit = IsoactionInternalInit();
  actionInit.port = _receivePortForUxIsolate.sendPort;

  //Allows for single isolate operations for developer convenience
  // _entryFunc(actionInit);
  //return;

  try {
    _isolate = await Isolate.spawn(
      _entryFunc,
      actionInit,
      paused: false,
      errorsAreFatal: false,
      debugName: 'Exec',
    );
    return;
  } catch (except) {
    _setError('Exception:' + except.toString());
  }
  _status = IsoBridgeStatus.error;
}