DerivedCirceCodec

monix.newtypes.integrations.DerivedCirceCodec

Derives a type-class instances for encoding and decoding JSON for any type implementing HasExtractor and HasBuilder type-class instances.

See https://circe.github.io/circe/codecs/custom-codecs.html.

WARN: we are not deriving io.circe.Codec, as it's an anti-pattern due to making code less generic. Also, due to Scala's subtyping it can lead to conflicts.

Attributes

Source
DerivedCirceCodec.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Inherited methods

protected def jsonDecode[T, S](c: HCursor)(implicit builder: Aux[T, S], dec: Decoder[S]): Result[T]

Attributes

Inherited from:
DerivedCirceDecoder
Source
DerivedCirceCodec.scala
protected def jsonEncode[T, S](a: T)(implicit extractor: Aux[T, S], enc: Encoder[S]): Json

Attributes

Inherited from:
DerivedCirceEncoder
Source
DerivedCirceCodec.scala

Implicits

Inherited implicits

implicit def jsonDecoder[T, S](implicit builder: Aux[T, S], dec: Decoder[S]): Decoder[T]

Attributes

Inherited from:
DerivedCirceDecoder
Source
DerivedCirceCodec.scala
implicit def jsonEncoder[T, S](implicit extractor: Aux[T, S], enc: Encoder[S]): Encoder[T]

Attributes

Inherited from:
DerivedCirceEncoder
Source
DerivedCirceCodec.scala