RichOption

final class RichOption[A](o: Option[A]) extends AnyVal

Provides conversions from Scala Option to Java Optional types

class AnyVal
trait Matchable
class Any

Value members

Concrete methods

def toJava: Optional[A]

Convert a Scala Option to a generic Java Optional

def toJavaPrimitive[O](shape: OptionShape[A, O]): O

Convert a Scala Option to a specialized Java Optional

Deprecated methods

@deprecated("Use `toJava` instead", "2.13.0")
def asJava: Optional[A]

Convert a Scala Option to a generic Java Optional

Deprecated
Source
OptionConverters.scala