Scala LanguageOption Class

Syntax

  • class Some[+T](value: T) extends Option[T]

  • object None extends Option[Nothing]

  • Option[T](value: T)

    Constructor to create either a Some(value) or None as appropriate for the value provided.