map<R> method

  1. @override
Result<R> map<R>(
  1. R transform(
    1. T data
    )
)
override

If this is a Success, applies transform to the data and wraps the outcome in a new Success. Otherwise propagates the Error unchanged.

Implementation

@override
Result<R> map<R>(R Function(T data) transform) => Error<R>(failure);