Ok<T extends Object?, E extends Object?> class

Inheritance

Constructors

Ok(T value)
const

Properties

hashCode int
The hash code for this object.
no setterinherited
isErr bool
no setteroverride
isOk bool
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value → T
final

Methods

andThen<U>(Result<U, E> f(T value)) Result<U, E>
override
err() → E?
override
fold<R extends Object?>({R onOk(T value)?, R onErr(E error)?}) → R
override
foldOne<R extends Object?>(R f(T? value, E? error)) → R
override
map<U>(U f(T value)) Result<U, E>
override
mapErr<F>(F f(E error)) Result<T, F>
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
ok() → T?
override
toString() String
A string representation of this object.
override
unwrap() → T
override
unwrapErr() → E
override
unwrapOr(T defaultValue) → T
override

Operators

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