CodecConfig

io.github.mbannour.mongo.codecs.CodecConfig
case class CodecConfig(noneHandling: NoneHandling)

Configuration for BSON codec generation behavior.

This configuration object encapsulates all codec generation options, making the API more type-safe and extensible than using boolean flags.

Value parameters

noneHandling

Strategy for handling None values in Option fields. ===Example Usage===

 val config = CodecConfig(
   noneHandling = NoneHandling.Ignore
 )

Attributes

Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def shouldEncodeNone: Boolean

Returns true if None values should be encoded as BSON null.

Returns true if None values should be encoded as BSON null.

Attributes

Helper method to set None handling to Encode - fluent API for functional configuration.

Helper method to set None handling to Encode - fluent API for functional configuration.

Attributes

Example
 builder.configure(_.withEncodeNone)

Helper method to set None handling to Ignore - fluent API for functional configuration.

Helper method to set None handling to Ignore - fluent API for functional configuration.

Attributes

Example
 builder.configure(_.withIgnoreNone)

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product