maybeWhen<TResult extends Object?> method Null safety

  1. @optionalTypeArgs
TResult maybeWhen<TResult extends Object?>(
  1. {TResult initial(
      )?,
    1. TResult data(
      1. T value
      )?,
    2. TResult loading(
        )?,
      1. TResult error(
        1. dynamic error
        )?,
      2. required TResult orElse(
          )}
        )
        @optionalTypeArgs, inherited

        Implementation

        @optionalTypeArgs
        TResult maybeWhen<TResult extends Object?>({
          TResult Function()? initial,
          TResult Function(T value)? data,
          TResult Function()? loading,
          TResult Function(dynamic error)? error,
          required TResult orElse(),
        }) =>
            throw _privateConstructorUsedError;