RxCommandAsync<TParam, TResult> constructor

RxCommandAsync<TParam, TResult>(
  1. AsyncFunc1<TParam, TResult>? func,
  2. Future<TResult> funcNoParam()?,
  3. Stream<bool?>? registration,
  4. bool emitInitialCommandResult,
  5. bool emitLastResult,
  6. bool emitsLastValueToNewSubscriptions,
  7. TResult? initialLastResult,
  8. bool noResult,
  9. String? debugName,
  10. bool noParamValue,
)

Implementation

factory RxCommandAsync(
    AsyncFunc1<TParam, TResult>? func,
    Future<TResult> Function()? funcNoParam,
    Stream<bool?>? registration,
    bool emitInitialCommandResult,
    bool emitLastResult,
    bool emitsLastValueToNewSubscriptions,
    TResult? initialLastResult,
    bool noResult,
    String? debugName,
    bool noParamValue) {
  return RxCommandAsync._(
      func,
      funcNoParam,
      emitsLastValueToNewSubscriptions || emitInitialCommandResult
          ? BehaviorSubject<TResult>()
          : PublishSubject<TResult>(),
      registration,
      emitLastResult,
      emitsLastValueToNewSubscriptions || emitInitialCommandResult,
      emitInitialCommandResult,
      initialLastResult,
      noResult,
      debugName,
      noParamValue);
}