ResourceResult
Provides convenience methods for ResourceResult.
Attributes
- Source
- ResourceResult.scala
- Graph
-
- Supertypes
- Self type
-
ResourceResult.type
Members list
Value members
Concrete methods
Evaluates the specified value, returning a CloseResult if an error occurs.
Evaluates the specified value, returning a CloseResult if an error occurs.
Attributes
- See also
-
ResourceResult.apply
- Example
-
scala> def f: Int = sys.error("something went wrong") scala> ResourceResult.close(f) res0: ResourceResult[Unit] = Left(CloseError: something went wrong) - Source
- ResourceResult.scala
Evaluates the specified value, returning an OpenResult if an error occurs.
Evaluates the specified value, returning an OpenResult if an error occurs.
Attributes
- See also
-
OpenResult.apply
- Example
-
scala> def f: Int = sys.error("something went wrong") scala> ResourceResult.open(f) res0: ResourceResult[Int] = Left(OpenError: something went wrong) - Source
- ResourceResult.scala
Evaluates the specified value, returning a ProcessResult if an error occurs.
Evaluates the specified value, returning a ProcessResult if an error occurs.
Attributes
- See also
-
ProcessResult.apply
- Example
-
scala> def f: Int = sys.error("something went wrong") scala> ResourceResult.process(f) res0: ResourceResult[Int] = Left(ProcessError: something went wrong) - Source
- ResourceResult.scala
Inherited methods
Turns the specified value into a failure.
Turns the specified value into a failure.
Attributes
- Inherited from:
- Simple
- Source
- ResultCompanion.scala
Turns a collection of results into a result of a collection.
Turns a collection of results into a result of a collection.
Attributes
- Inherited from:
- Simple
- Source
- ResultCompanion.scala
Turns the specified value into a success.
Turns the specified value into a success.
Attributes
- Inherited from:
- Simple
- Source
- ResultCompanion.scala