Ok<O, E> class
final
Represents a Success
Constructors
- Ok(O ok)
-
Create an
OkResult with the given valueconst
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- isErr → bool
-
is err?
no setterinherited
- isOk → bool
-
is ok?
no setterinherited
- ok → O
-
Wrapped value
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- unwrap → O
-
Unwraps the value of a possible Ok, in case of Err it will throw an State Error
no setterinherited
- unwrapErr → E
-
Unwraps the value of a possible Err, in case of Ok it will throw an State Error
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
retag<
O2> () → Result< O2, E> -
Returns a new Result with the same error type
Ebut a different success typeO2, only if this result is an Err.inherited -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override