EitherValuable

class EitherValuable[L, R](either: Either[L, R], pos: Position) extends Serializable

Wrapper class that adds a value method to Either, allowing you to make statements to inspect the value if a Right, like:

either.value should be > 9
Value parameters:
either

An Either to convert to EitherValuable, which provides the value method.

trait Serializable
class Object
trait Matchable
class Any

Value members

Concrete methods

def value: R

Returns the Right value contained in the wrapped RightProjection, if defined as a Right, else throws TestFailedException with a detail message indicating the Either was defined as a Right, not a Left.

Returns the Right value contained in the wrapped RightProjection, if defined as a Right, else throws TestFailedException with a detail message indicating the Either was defined as a Right, not a Left.