Extracts the base value from this type. The function throws an error with the provided message if there is no value provided.
The message to throw if the Option<T> is a None.
The value of the Option<T> if it is a Some<T>.
Utility function to determine whether this Option<T> type is a None type.
true if the Option<T> is a None, otherwise false.
A utility function to convert an Option
An Option
Extracts the base value from this type, not checking if the value is None.
The raw unchecked inner value of the Option<T>
Extracts the base value from this type. If there is no value in the Option<T>, the function will return whatever you provided as the
default value, even if that value was not provided (undefined).
OptionaldefaultValue: null | TThe value to return if the Option<T> is a None
The possibly undefined | null value of the Option<T>.
Extracts the base value from this type. This function will throw an error if there is no value in the Option<T>.
The value of the Option<T>.
maps the value of this Option to a Option using the provided function. This is useful if you wish to chain
multiple Option types together. Flattens the Option<Option> to an Option