Class

cats.syntax

EitherObjectOps

Related Doc: package syntax

Permalink

final class EitherObjectOps extends AnyVal

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. EitherObjectOps
  2. AnyVal
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new EitherObjectOps(either: Either.type)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def catchNonFatal[A](f: ⇒ A): Either[Throwable, A]

    Permalink
  6. def catchOnly[T >: Null <: Throwable]: CatchOnlyPartiallyApplied[T]

    Permalink

    Evaluates the specified block, catching exceptions of the specified type and returning them on the left side of the resulting Either.

    Evaluates the specified block, catching exceptions of the specified type and returning them on the left side of the resulting Either. Uncaught exceptions are propagated.

    For example:

    scala> import cats.implicits._ // get syntax for Either
    scala> Either.catchOnly[NumberFormatException] { "foo".toInt }
    res0: Either[NumberFormatException, Int] = Left(java.lang.NumberFormatException: For input string: "foo")
  7. def fromOption[A, B](o: Option[B], ifNone: ⇒ A): Either[A, B]

    Permalink

    Converts an Option[B] to an Either[A, B], where the provided ifNone values is returned on the left of the Either when the specified Option is None.

  8. def fromTry[A](t: Try[A]): Either[Throwable, A]

    Permalink

    Converts a Try[A] to a Either[Throwable, A].

  9. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  10. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  11. def left[A, B](a: A): Either[A, B]

    Permalink
  12. def leftNec[A, B](a: A): EitherNec[A, B]

    Permalink
  13. def leftNel[A, B](a: A): EitherNel[A, B]

    Permalink
  14. def leftNes[A, B](a: A)(implicit O: Order[A]): EitherNes[A, B]

    Permalink
  15. def right[A, B](b: B): Either[A, B]

    Permalink
  16. def rightNec[A, B](b: B): EitherNec[A, B]

    Permalink
  17. def rightNel[A, B](b: B): EitherNel[A, B]

    Permalink
  18. def rightNes[A, B](b: B)(implicit O: Order[B]): EitherNes[A, B]

    Permalink
  19. def toString(): String

    Permalink
    Definition Classes
    Any

Inherited from AnyVal

Inherited from Any

Ungrouped