Optional

An optional of type T

Constructors

this
this(T value, bool isSome)
Undocumented in source.

Members

Functions

get
T get()

Gets the value of the optional but leaving it as it.

isNone
bool isNone()

Returns true if the optional is a None; false otherwise

isSome
bool isSome()

Returns true if the optional is a Some; false otherwise

take
T take()

Takes the value out of the optional, leaving a None in it's place

Static functions

none
Optional none()

Creates a None

some
Optional some(T value)

Creates a Some

Meta