KeyDecoder

trait KeyDecoder[A] extends Serializable

A type class that provides a conversion from a string used as a JSON key to a value of type A.

Companion:
object
Source:
KeyDecoder.scala
trait Serializable
class Object
trait Matchable
class Any

Value members

Abstract methods

def apply(key: String): Option[A]

Attempt to convert a String to a value.

Attempt to convert a String to a value.

Source:
KeyDecoder.scala

Concrete methods

final def flatMap[B](f: A => KeyDecoder[B]): KeyDecoder[B]

Construct an instance for type B from an instance for type A given a monadic function.

Construct an instance for type B from an instance for type A given a monadic function.

Source:
KeyDecoder.scala
final def map[B](f: A => B): KeyDecoder[B]

Construct an instance for type B from an instance for type A.

Construct an instance for type B from an instance for type A.

Source:
KeyDecoder.scala