Home Reference Source Repository
public interface | source

M

Direct Implemented:

Indirect Implemented:

interface M<T>{

protected just<T,U>(f: MF<T, U>, v: T): Pr<U>;

protected fail(e: Error | string): Error;

}

Method Summary

Protected Methods
protected

fail(e: Error | string): Error

Execute on error occur.

protected

just(f: function(v: T), v: T): Pr<U>

Extracts value from monad.

Protected Methods

protected fail(e: Error | string): Error source

Execute on error occur.

Params:

NameTypeAttributeDescription
e Error | string

Error obj. or string.

Return:

Error

protected just(f: function(v: T), v: T): Pr<U> source

Extracts value from monad.

Params:

NameTypeAttributeDescription
f function(v: T)

transformation function for a monad.

v T

underlying value.

Return:

Pr<U>

extracts transformed value by f(v).