Trial

com.phasmidsoftware.lascala.Trial
See theTrial companion class
object Trial

Attributes

Companion
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
Trial.type

Members list

Type members

Inherited and Abstract types

type MirroredElemLabels <: Tuple

The names of the product elements.

The names of the product elements.

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type.

The name of the type.

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def lift[V, T](f: V => T): Trial[V, T]
def none[V, T](f: Any => Throwable): Trial[V, T]

The following method creates a null trial which can be used at the start or end of a chain of functions

The following method creates a null trial which can be used at the start or end of a chain of functions

Type parameters

T

the underlying type of the resulting Try

V

the type of the input parameter

Value parameters

f

the function which will create a Throwable based on the input value.

Attributes

Returns

a terminator trial which always fails

def none[V, T]: Trial[V, T]

The following method creates a null trial which can be used at the start or end of a chain of functions. The exception wrapped in this Trial is an Exception("null trial")

The following method creates a null trial which can be used at the start or end of a chain of functions. The exception wrapped in this Trial is an Exception("null trial")

Type parameters

T

the underlying type of the resulting Try

V

the type of the input parameter

Attributes

Returns

a terminator trial which always fails