getOrElse
For the Map
's getOrElse
function go here.
trait Option[A] {
def getOrElse[B >: A](b: => B): B
}
getOrElse
returns the wrapped value when this Option
is Some
.
When this Option
is None
the default value b
is returned.