package data-encoding

  1. Overview
  2. Docs
type t = bson
val construct : 't Encoding.t -> 't -> bson

Construct a BSON object from an encoding.

val destruct : 't Encoding.t -> bson -> 't

Destruct a BSON object into a value. Fail with an exception if the JSON object and encoding do not match..