Kaptos
Toggle table of contents
0.1.2-beta
common
Target filter
common
Switch theme
Search in API
Skip to content
Kaptos
Kaptos
/
xyz.mcxross.kaptos.model
/
Result
Result
sealed
class
Result
<
out
V
,
out
E
>
Inheritors
Ok
Err
Members
Members & Extensions
Types
Err
Link copied to clipboard
data
class
Err
<
out
E
>
(
val
error
:
E
)
:
Result
<
Nothing
,
E
>
Ok
Link copied to clipboard
data
class
Ok
<
out
V
>
(
val
value
:
V
)
:
Result
<
V
,
Nothing
>
Functions
error
Or
Null
Link copied to clipboard
fun
errorOrNull
(
)
:
E
?
expect
Link copied to clipboard
inline
fun
expect
(
message
:
(
)
->
String
)
:
V
fun
expect
(
message
:
String
)
:
V
expect
Err
Link copied to clipboard
inline
fun
expectErr
(
message
:
(
)
->
String
)
:
E
get
Or
Null
Link copied to clipboard
fun
getOrNull
(
)
:
V
?
to
Internal
Result
Link copied to clipboard
fun
<
V
,
E
>
Result
<
V
,
E
>
.
toInternalResult
(
)
:
Result
<
V
,
E
>
unwrap
Link copied to clipboard
fun
unwrap
(
)
:
V
unwrap
Err
Link copied to clipboard
fun
unwrapErr
(
)
:
E