Module optional.or

Gets the value or else something else

Functions

NameDescription
frontOr(value) If value is valid, it returns the internal value. This means .front for a range, .get for a Nullable!T, etc. If value is invalid, then elseValue is returned. If an elsePred is provided than that is called.
frontOrThrow(value) Same as frontOr except it throws an error if it can't get the value
or(value) If value is valid, it returns the value. If value is invalid, then elseValue is returned. If an elsePred is provided than that is called.

Classes

NameDescription
FrontOrThrowException An exception that's throw by frontOrThrow should the exception maker throw