concurrency ~master (2022-01-07T14:23:47Z)
Dub
Repo
Result
concurrency
Undocumented in source.
struct
Result (
T
) {
import
mir
.
algebraic
:
Algebraic
,
Nullable
;
;
import
mir
.
algebraic
:
Algebraic
,
Nullable
;
;
struct
Value
(T)
;
static if
(
is(T == void)
)
Nullable
!(
Cancelled
,
Exception
)
result
;
static if
(!(
is(T == void)
))
Algebraic
!(
Value
!
T
,
Cancelled
,
Exception
)
result
;
this
(T v);
this
(Cancelled c);
this
(Exception e);
bool
isCancelled
();
bool
isError
();
bool
isOk
();
static if
(
!is(T == void)
)
T
value
();
Exception
error
();
void
assumeOk
();
}
Constructors
this
this
(T v)
Undocumented in source.
this
this
(Cancelled c)
Undocumented in source.
this
this
(Exception e)
Undocumented in source.
Members
Functions
assumeOk
void
assumeOk
()
Undocumented in source. Be warned that the author may not have intended to support it.
error
Exception
error
()
Undocumented in source. Be warned that the author may not have intended to support it.
isCancelled
bool
isCancelled
()
Undocumented in source. Be warned that the author may not have intended to support it.
isError
bool
isError
()
Undocumented in source. Be warned that the author may not have intended to support it.
isOk
bool
isOk
()
Undocumented in source. Be warned that the author may not have intended to support it.
value
T
value
()
Undocumented in source. Be warned that the author may not have intended to support it.
Structs
Value
struct
Value
(T)
Undocumented in source.
Variables
result
Nullable
!(
Cancelled
,
Exception
)
result
;
Undocumented in source.
result
Algebraic
!(
Value
!
T
,
Cancelled
,
Exception
)
result
;
Undocumented in source.
Meta
Source
See Implementation
concurrency
modules
bitfield
data
error
executor
fork
nursery
operations
receiver
scheduler
sender
signal
slist
stoptoken
stream
thread
timer
timingwheels
utils
functions
isMainThread
setTopLevelStopSource
syncWait
sync_wait
static variables
cancelledException
parentStopSource
structs
Cancelled
Result
SyncWaitReceiver2
templates
match