class EnumDiscriminatorCodec[T] extends Encoder[T] with Decoder[T]
Encodes the values of a trivial disjunct enum hierarchy into a Json string. Note: is using circe json.
TODO: Circe's KeyDecoder and KeyEncoder somehow have a similar meaning however they are abstract classes so we cannot easily mix them together. Maybe it's a good idea to clean up.
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- EnumDiscriminatorCodec
- Decoder
- Encoder
- Serializable
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Instance Constructors
- new EnumDiscriminatorCodec(mapping: Seq[(String, T)])
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def apply(c: HCursor): Result[T]
- Definition Classes
- EnumDiscriminatorCodec → Decoder
- def apply(a: T): Json
- Definition Classes
- EnumDiscriminatorCodec → Encoder
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- final def at(field: String): Decoder[T]
- Definition Classes
- Decoder
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
- final def contramap[B](f: (B) => T): Encoder[B]
- Definition Classes
- Encoder
- def decodeAccumulating(c: HCursor): AccumulatingResult[T]
- Definition Classes
- Decoder
- final def decodeJson(j: Json): Result[T]
- Definition Classes
- Decoder
- final def either[B](decodeB: Decoder[B]): Decoder[Either[T, B]]
- Definition Classes
- Decoder
- def elementToString(element: T): String
- final def emap[B](f: (T) => Either[String, B]): Decoder[B]
- Definition Classes
- Decoder
- final def emapTry[B](f: (T) => Try[B]): Decoder[B]
- Definition Classes
- Decoder
- final def ensure(errors: (T) => List[String]): Decoder[T]
- Definition Classes
- Decoder
- final def ensure(pred: (T) => Boolean, message: => String): Decoder[T]
- Definition Classes
- Decoder
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def flatMap[B](f: (T) => Decoder[B]): Decoder[B]
- Definition Classes
- Decoder
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def handleErrorWith(f: (DecodingFailure) => Decoder[T]): Decoder[T]
- Definition Classes
- Decoder
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def kleisli: Kleisli[Result, HCursor, T]
- Definition Classes
- Decoder
- final def map[B](f: (T) => B): Decoder[B]
- Definition Classes
- Decoder
- final def mapJson(f: (Json) => Json): Encoder[T]
- Definition Classes
- Encoder
- val mapping: Seq[(String, T)]
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def or[AA >: T](d: => Decoder[AA]): Decoder[AA]
- Definition Classes
- Decoder
- final def prepare(f: (ACursor) => ACursor): Decoder[T]
- Definition Classes
- Decoder
- final def product[B](fb: Decoder[B]): Decoder[(T, B)]
- Definition Classes
- Decoder
- def stringToElement(name: String): Option[T]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def tryDecode(c: ACursor): Result[T]
- Definition Classes
- Decoder
- def tryDecodeAccumulating(c: ACursor): AccumulatingResult[T]
- Definition Classes
- Decoder
- final def validate(pred: (HCursor) => Boolean, message: => String): Decoder[T]
- Definition Classes
- Decoder
- final def validate(errors: (HCursor) => List[String]): Decoder[T]
- Definition Classes
- Decoder
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def withErrorMessage(message: String): Decoder[T]
- Definition Classes
- Decoder
Deprecated Value Members
- final def accumulating(c: HCursor): AccumulatingResult[T]
- Definition Classes
- Decoder
- Annotations
- @deprecated
- Deprecated
(Since version 0.12.0) Use decodeAccumulating
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated