BsonSchemaCodec

zio.blocks.schema.bson.BsonSchemaCodec

Attributes

Source
BsonSchemaCodec.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Type members

Classlikes

object Codecs

Runtime-codec aliases retained for source compatibility.

Runtime-codec aliases retained for source compatibility.

Attributes

Source
BsonSchemaCodec.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Codecs.type
class Config

Configuration for the BSON schema codec.

Configuration for the BSON schema codec.

Value parameters

classNameMapping

The mapping of class names.

ignoreExtraFields

If true (default), extra fields in BSON documents are silently ignored during decoding. If false, decoding will fail with an error when encountering unknown fields.

sumTypeHandling

The handling of sum types.

useNativeObjectId

If true, org.bson.types.ObjectId will be encoded/decoded using BSON's native ObjectId type (BsonType.OBJECT_ID). If false, ObjectId will be treated as a regular wrapper and encoded as a string. Default is false. Note: When using ObjectIdSupport.objectIdSchema, this is automatically detected regardless of this setting.

Attributes

Companion
object
Source
BsonSchemaCodec.scala
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object Config
object Config extends Config

Attributes

Companion
class
Source
BsonSchemaCodec.scala
Supertypes
class Config
class Object
trait Matchable
class Any
Self type
Config.type

Attributes

Companion
trait
Source
BsonSchemaCodec.scala
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
sealed trait SumTypeHandling

Attributes

Companion
object
Source
BsonSchemaCodec.scala
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Types

type TermMapping = String => String

Attributes

Source
BsonSchemaCodec.scala

Value members

Concrete methods

def bsonCodec[A](schema: Schema[A], config: Config): BsonCodec[A]

Compatibility facade for BsonCodecDeriver.

Compatibility facade for BsonCodecDeriver.

Attributes

Source
BsonSchemaCodec.scala
def bsonCodec[A](schema: Schema[A]): BsonCodec[A]

Attributes

Source
BsonSchemaCodec.scala
def bsonDecoder[A](schema: Schema[A], config: Config): BsonDecoder[A]

Derives a BSON decoder using the shared schema derivation framework.

Derives a BSON decoder using the shared schema derivation framework.

Attributes

Source
BsonSchemaCodec.scala
def bsonDecoder[A](schema: Schema[A]): BsonDecoder[A]

Attributes

Source
BsonSchemaCodec.scala
def bsonEncoder[A](schema: Schema[A], config: Config): BsonEncoder[A]

Derives a BSON encoder using the shared schema derivation framework.

Derives a BSON encoder using the shared schema derivation framework.

Attributes

Source
BsonSchemaCodec.scala
def bsonEncoder[A](schema: Schema[A]): BsonEncoder[A]

Attributes

Source
BsonSchemaCodec.scala