Open Sidebar
Close Sidebar
CrystalDoc.info
Source code
Shards.info
therapy
main
Therapy
ArrayType
BaseType
BoolType
Check
Error
Int32Type
ObjectType
OptionalType
ParseContext
Result
Failure
Success
StringType
SubContext
TupleType
Built with Crystal 1.9.2
2023-10-07 18:06:28 UTC
struct
Therapy::Result::Success(T)
Therapy::Result::Success(T)
Therapy::Result(T)
Struct
Value
Object
Defined in:
therapy/result.cr
Constructors
.new
(value : T)
Instance Method Summary
#errors
: Array(Therapy::Error)
#failure?
: Bool
#success?
: Bool
#value
: T
Instance methods inherited from struct
Therapy::Result(T)
errors : Array(Therapy::Error)
errors
,
failure? : Bool
failure?
,
initialize
initialize
,
map(&block : T -> Y) : Result(Y) forall Y
map
,
success? : Bool
success?
,
value : T
value
Constructor methods inherited from struct
Therapy::Result(T)
new
new
Constructor Detail
def self.
new
(value : T)
#
[
View source
]
Instance Method Detail
def
errors
: Array(
Therapy::Error
)
#
[
View source
]
def
failure?
: Bool
#
[
View source
]
def
success?
: Bool
#
[
View source
]
def
value
: T
#
[
View source
]