None class

Inheritance
Available Extensions

Constructors

None()
const

Properties

hashCode int
The hash code for this object.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

andThen<B>(covariant Option<B> then()) Option<B>
If this Option is a Some, then return the result of calling then. Otherwise return None.
inherited
ap<B>(covariant Option<B Function(Never t)> a) Option<B>
Apply the function contained inside a to change the value of type T to a value of type B.
inherited
call<B>(covariant Option<B> chain) Option<B>
Chain multiple Options.
inherited
chainFirst<B>(covariant Monad<_OptionHKT, B> chain(Never a)) HKT<_OptionHKT, Never>
inherited
duplicate() Option<Option<Never>>
Wrap this Option inside another Option.
inherited
extend<Z>(Z f(Option<Never> t)) Option<Z>
Change the value of Option from type T to type Z based on the value of Option<T> using function f.
override
filter(bool f(Never t)) Option<Never>
If this Option is a Some and calling f returns true, then return this Some. Otherwise return None.
inherited
filterMap<Z>(Option<Z> f(Never t)) Option<Z>
If this Option is a Some and calling f returns Some, then return this Some. Otherwise return None.
override
flatMap<B>(covariant Option<B> f(Never t)) Option<B>
Used to chain multiple functions that return a Option.
override
flatMapNullable<B>(B? f(Never t)) Option<B>
Return a new Option that calls Option.fromNullable on the result of of the given function f.
inherited
flatMapThrowable<B>(B f(Never t)) Option<B>
Return a new Option that calls Option.tryCatch with the given function f.
inherited
fold<B>(B onNone(), B onSome(Never t)) → B
Execute onSome when value is Some, otherwise execute onNone.
inherited
isNone() bool
Return true when value is None.
override
isSome() bool
Return true when value is Some.
override
map<B>(B f(Never t)) Option<B>
Change the value of type T to a value of type B using function f.
override
map2<C, D>(covariant Option<C> mc, D f(Never t, C c)) Option<D>
Change type of this Option based on its value of type T and the value of type C of another Option.
override
map3<C, D, E>(covariant Option<C> mc, covariant Option<D> md, E f(Never t, C c, D d)) Option<E>
Change type of this Option based on its value of type T, the value of type C of a second Option, and the value of type D of a third Option.
override
match<B>(B onNone(), B onSome(Never t)) → B
Execute onSome when value is Some, otherwise execute onNone.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
partition(bool f(Never t)) → (Option<Never>, Option<Never>)
Return a record. If this Option is a Some:
inherited
partitionMap<Z, Y>(Either<Z, Y> f(Never t)) → (Option<Z>, Option<Y>)
Return a record that contains as first value a Some when f returns Left, otherwise the Some will be the second value of the tuple.
inherited
pure<B>(B b) Option<B>
Return a Some containing the value b.
inherited
toEither<L>(L onLeft()) Either<L, Never>
Build an Either from Option.
inherited
toIOOption() IOOption<Never>
Convert this Option to a IOOption.
inherited
toJson(Object? toJsonT(Never p1)) Object?
Converts to Json.
override
toNullable() Null
Return value of type T when this Option is a Some, null otherwise.
override
toString() String
A string representation of this object.
override
toTaskOption() TaskOption<Never>
Convert this Option to a TaskOption.
inherited

Operators

operator ==(Object other) bool
The equality operator.
override