abstract class CRZ::Containers::Result(T, E)

Overview

base class

Included Modules

Direct Known Subclasses

Defined in:

crz/result.cr

Class Method Summary

Instance Method Summary

Macro Summary

Instance methods inherited from module CRZ::Monad(T)

<<(other : Monad(B)) : Monad(A) forall B <<, >=(block : A -> Monad(B)) : Monad(B) forall B >=, >>(other : Monad(B)) : Monad(B) forall B >>, ap(func : Applicative(A -> B)) : Applicative(B) forall B ap, map(&block : A -> B) : Monad(B) forall B map

Instance methods inherited from module CRZ::Applicative(T)

*(func : Applicative(A -> B)) : Applicative(B) forall B *

Class methods inherited from module CRZ::Applicative(T)

of(value : A) : Applicative(A) forall A of

Instance methods inherited from module CRZ::Functor(T)

replace(other : Functor(B), v : A) : Functor(A) replace

Class Method Detail

def self.of(value : T) : Result(T, E) #

[View source]

Instance Method Detail

def bind(&block : T -> Result(U, E)) : Result(U, E) forall U #

[View source]
def has_value : Bool #

[View source]
def map(&block : T -> U) : Result(U, E) forall U #

[View source]
def unwrap : T #

[View source]

Macro Detail

macro match(val, cases) #

[View source]