Skip to content

Unsuccessful

sealed interface Unsuccessful<out Failure>

Operations that are not successful; common supertype of Incomplete and Failure.

Note that a Success value with progress information is not included in this hierarchy, as it is successful.

Due to backwards-compatibility considerations, this cannot be a subtype of ProgressiveOutcome. If you have an instance of this interface and need a ProgressiveOutcome, use upcast.

Inheritors

Properties

progress

The progression of this unsuccessful value.

See ProgressiveOutcome.

Functions

upcast

Type-safe way to convert between an Unsuccessful and a ProgressiveOutcome.

In theory, this would be an implicit upcast. However, ProgressiveOutcome is a class, and Unsuccessful is an interface, so the subtype relationship cannot be declared to the compiler.