AnnotationsSyntax

implicit

Syntax for allowing annotations to be added to log tree nodes.

The best way to see how this syntax works is to take a look at the annotations example on GitHub.

Here is a short example:

import scalaz.syntax.show._

val syntax = new LogTreeSyntax[String] {}
import syntax._

val result = 1 ~> "One" ~~ Set("Annotating with a string", "And another")
println(result.run.value)
// Will print: \/-(1) - note that the 'right' means ''success''

println(result.run.written.shows)
// Will print:
// One - [Annotating with a string, And another]
class Object
trait Matchable
class Any

Value members

Concrete methods

def allAnnotations: Set[Annotation]

Get the union of all annotations in the log tree of the DescribedComputation.

Get the union of all annotations in the log tree of the DescribedComputation.

def annotateWith(annotations: Set[Annotation]): DescribedComputation[V]
def annotateWith(annotation: Annotation): DescribedComputation[V]

Equivalent to ~~ annotation

Equivalent to ~~ annotation

def ~~(annotations: Set[Annotation]): DescribedComputation[V]
def ~~(annotation: Annotation): DescribedComputation[V]

Syntactic sugar equivalent to annotateWith(annotation)

Syntactic sugar equivalent to annotateWith(annotation)