Prism

dynosaur.Prism
See thePrism companion class
object Prism

Attributes

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

Members list

Type members

Inherited 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 fromPartial[A, B](tryGet: PartialFunction[A, B])(inject: B => A): Prism[A, B]

Returns a new Prism instance using the specified tryGet partial function and inject function.

Returns a new Prism instance using the specified tryGet partial function and inject function.

Attributes

Implicits

Implicits

implicit def identity[A]: Prism[A, A]

Returns a new Prism for the specified type.

Returns a new Prism for the specified type.

Attributes

implicit def left[A, B]: Prism[Either[A, B], Left[A, B]]

Returns a new Prism from Either[A, B] to Left[A, B].

Returns a new Prism from Either[A, B] to Left[A, B].

Attributes

implicit def none[A]: Prism[Option[A], None.type]

Returns a new Prism from Option to None.

Returns a new Prism from Option to None.

Attributes

implicit def right[A, B]: Prism[Either[A, B], Right[A, B]]

Returns a new Prism from Either[A, B] to Right[A, B].

Returns a new Prism from Either[A, B] to Right[A, B].

Attributes

final implicit def some[A]: Prism[Option[A], Some[A]]

Returns a new Prism from Option to Some.

Returns a new Prism from Option to Some.

Attributes

Inherited implicits

final implicit def derive[S, A <: S](implicit tag: ClassTag[A]): Prism[S, A]

Returns a new Prism for the specified supertype and subtype.

Returns a new Prism for the specified supertype and subtype.

Relies on class tags. Since the function is implicit, Prisms are available implicitly for any supertype and subtype relationships.

Attributes

Inherited from:
LowPrioPrism (hidden)