@SuppressWarnings("unchecked")
	default <A> Response<A> map(final Function<? super T, ? extends A> fn) {
		requireNonNull(fn);

		return switch (this) {
			case Success(var s, var h, var r, var b) -> new Success<>(s, h, r, fn.apply(b));
			case Response.Failure<T> f -> (Failure<A>)f;
		};
	}
Applies the mapping function to the (success) response object. Errors are
returned unchanged.

@param fn the mapping function
@return the mapped response object
@param <A> the new response body type
jenetics.incubator/src/main/java/io/jenetics/incubator/restful/Response.java