Alternative
turbolift.effects.Alternative
case object Alternative extends ChoiceSignature
Virtual instance of ChoiceEffect
Allows invoking operations of ChoiceEffect, without the need of knowing its concrete instance. Alternative is designed to "match" the nearest (innermost) instance of ChoiceEffect currently present in the effect stack.
This is needed for making the following mechanisms to work:
- Guards in
for
comprehensions useAlternative.empty
- Binary operators
+!
and++!
(similar to<+>
from Cats) useplus
andplusPar
.
Attributes
- Graph
-
- Supertypes
-
trait Singletontrait Producttrait Mirrortrait Serializabletrait Producttrait Equalstrait ChoiceSignaturetrait Signatureclass Objecttrait Matchableclass Any
- Self type
-
Alternative.type
Members list
In this article