merge

@JvmName(name = "merge2")
inline fun <T> Iterable<ApiResult<T>>.merge(): ApiResult<List<T>>

Merges all results into a single List, or if any has failed, returns Error.


inline fun <T> merge(results: Iterable<ApiResult<T>>): ApiResult<List<T>>

Merges all results into a single List, or if any has failed, returns Error.


inline fun <T> ApiResult<T>.merge(results: Iterable<ApiResult<T>>): ApiResult<List<T>>

Merges this results and all other results into a single result of type T.