maybeWhen<T> method

T maybeWhen<T>({
  1. T? roomId()?,
  2. T? sender()?,
  3. required T orElse(),
})

Implementation

T maybeWhen<T>({
  T? Function()? roomId,
  T? Function()? sender,
  required T Function() orElse,
}) =>
    {
      GroupKey.roomId: roomId,
      GroupKey.sender: sender,
    }[this]
        ?.call() ??
    orElse();