RxCommandAsync<TParam, TResult> constructor

RxCommandAsync<TParam, TResult>(AsyncFunc1<TParam, TResult> func, Observable<bool> canExecute, bool emitInitialCommandResult, bool emitLastResult, bool emitsLastValueToNewSubscriptions, TResult initialLastResult)

Implementation

factory RxCommandAsync(AsyncFunc1<TParam, TResult> func, Observable<bool> canExecute, bool emitInitialCommandResult,
    bool emitLastResult, bool emitsLastValueToNewSubscriptions, TResult initialLastResult) {
  return new RxCommandAsync._(
      func,
      emitsLastValueToNewSubscriptions || emitInitialCommandResult
          ? new BehaviorSubject<TResult>()
          : new PublishSubject<TResult>(),
      canExecute,
      emitLastResult,
      emitsLastValueToNewSubscriptions || emitInitialCommandResult,
      emitInitialCommandResult,
      initialLastResult);
}