CaseClassCodecGenerator

io.github.mbannour.bson.macros.CaseClassCodecGenerator

Macro-based codec generator for BSON serialization and deserialization of case classes.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

inline def generateCodec[T](codecRegistry: CodecRegistry)(using classTag: ClassTag[T]): Codec[T]

Entry point for generating a BSON codec for a specific type T. Validates that T is a case class at compile-time.

Entry point for generating a BSON codec for a specific type T. Validates that T is a case class at compile-time.

Type parameters

T

Type for which the codec is generated.

Value parameters

codecRegistry

CodecRegistry used for nested fields.

Attributes

Returns

A BSON codec instance for type T.

def generateCodecImpl[T : Type](codecRegistry: Expr[CodecRegistry], classTag: Expr[ClassTag[T]])(implicit evidence$1: Type[T], Quotes): Expr[Codec[T]]