Trait/Object

scalaz

Optional

Related Docs: object Optional | package scalaz

Permalink

trait Optional[F[_]] extends AnyRef

Abstraction over a container/context which may or may not provide a value.

F

the container/context type

Self Type
Optional[F]
Source
Optional.scala
See also

syntax.OptionalOps

Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Optional
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def pextract[B, A](fa: F[A]): \/[F[B], A]

    Permalink

    If fa has an a, return it; otherwise it must be universally quantified.

Concrete Value Members

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

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

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. def ?[A, X](fa: F[A])(some: ⇒ X, none: ⇒ X): X

    Permalink

    Returns some if this context is defined, otherwise none.

  5. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  8. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  9. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  11. def getOrElse[A](fa: F[A])(default: ⇒ A): A

    Permalink

    Returns the value within the context if defined or else the value of default.

  12. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  13. def isDefined[A](fa: F[A]): Boolean

    Permalink

    Returns true if a value is defined within the context.

  14. final def isEmpty[A](fa: F[A]): Boolean

    Permalink

    Returns true if no value is defined within the context.

  15. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  16. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. final def nonEmpty[A](fa: F[A]): Boolean

    Permalink

    Returns true if a value is defined within the context.

    Returns true if a value is defined within the context. This is an alias for isDefined.

  18. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  19. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  20. val optionalSyntax: OptionalSyntax[F]

    Permalink
  21. def orElse[A](fa: F[A])(alternative: ⇒ F[A]): F[A]

    Permalink

    Returns given context if it is defined or else the value of the alternative.

  22. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  23. def toMaybe[A](fa: F[A]): Maybe[A]

    Permalink

    Returns this context converted to the Maybe context.

  24. def toOption[A](fa: F[A]): Option[A]

    Permalink

    Returns this context converted to the Option context.

  25. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  26. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped