final class OptionOps[A] extends AnyVal

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

Instance Constructors

  1. new OptionOps(option: Option[A])

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    Any
  2. final def ##(): Int
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def forEmpty(sideEffect: ⇒ Unit): Option[A]

    Apply side effect only if Option is empty.

    Apply side effect only if Option is empty. It's a bit like foreach for None

    sideEffect

    - code to be executed if option is empty

    returns

    the same option

    Example:
    1. captionOpt.forEmpty(logger.warn("caption is empty")).foreach(setCaption)
  6. def getClass(): Class[_ <: AnyVal]
    Definition Classes
    AnyVal → Any
  7. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  8. def toNOpt: commons.NOpt[A]
  9. def toOpt: commons.Opt[A]

    Converts this Option into Opt.

    Converts this Option into Opt. Because Opt cannot hold null, Some(null) is translated to Opt.Empty.

  10. def toOptArg: commons.OptArg[A]

    Converts this Option into OptArg.

    Converts this Option into OptArg. Because OptArg cannot hold null, Some(null) is translated to OptArg.Empty.

  11. def toOptRef[B >: Null](implicit boxing: Boxing[A, B]): commons.OptRef[B]

    Converts this Option into OptRef, changing the element type into boxed representation if necessary (e.g.

    Converts this Option into OptRef, changing the element type into boxed representation if necessary (e.g. Boolean into java.lang.Boolean). Because OptRef cannot hold null, Some(null) is translated to OptRef.Empty.

  12. def toString(): String
    Definition Classes
    Any

Inherited from AnyVal

Inherited from Any

Ungrouped