rd-core
2023.2.3
rd-core
/
com.jetbrains.rd.util
/
Result
Result
sealed
class
Result
<
out
T
>
Content copied to clipboard
Classical Result monad
Types
Functions
Inheritors
Types
Companion
Link copied to clipboard
object
Companion
Content copied to clipboard
Failure
Link copied to clipboard
class
Failure
(
val
error
:
Throwable
)
:
Result
<
Nothing
>
Content copied to clipboard
Success
Link copied to clipboard
class
Success
<
T
>
(
val
value
:
T
)
:
Result
<
T
>
Content copied to clipboard
Functions
transform
Link copied to clipboard
inline
fun
<
E
>
transform
(
onSuccess
:
(
T
)
->
E
,
onFailure
:
(
Throwable
)
->
E
)
:
E
Content copied to clipboard
unwrap
Link copied to clipboard
fun
unwrap
(
)
:
T
Content copied to clipboard
Inheritors
Success
Link copied to clipboard
Failure
Link copied to clipboard