transform


Description:

public abstract Result<A> transform<A> (owned TransformFunc<A,G> func)

Creates a new future by applying the given function to this future, in future -- when this future is completed.

The returned object of the function may or may not be directly used. Depending on the internal implementation, A new future object will be created with the value or exception of it and returned, instead of returning it directly.

If the function returns not a Future but a Result, the result is mapped to a future.

Parameters:

func

a function applied to this result

Returns:

[Future<A>] the new future




2022 vala-language.org