Commit Graph

3 Commits

Author SHA1 Message Date
kaczmarczyck
8a53986961 CBOR API changes (#639)
* adds extract_* functions to CBOR library

* hides Value implementation details

* CBOR API fixes

* README adapted to API changes
2023-08-11 17:28:59 +02:00
David Drysdale
0287a09573 cbor: allow user to control nesting (#329)
* cbor: allow user to control nesting

 - Make the default read/write entrypoints allow infinite nesting.
 - Add {read,write}_nested() entrypoints that allow the crate user to
   control the depth of nesting that's allowed.
 - Along the way, convert the write[_nested] variants to return a
   `Result<(), EncoderError>` rather than a bool.  This exposes
   more failure information (and forces the caller to take notice
   of those tailures), and allows use of the ? operator.

* fixup: transmute error

Co-authored-by: kaczmarczyck <43844792+kaczmarczyck@users.noreply.github.com>
2021-06-18 19:39:54 +02:00
David Drysdale
3aca5fbc74 cbor: prepare for publishing as standalone crate
- Add an example of usage
- Add a minimal README, including the example code
- Document public items
- Add more info to Cargo.toml
2021-06-16 17:16:05 +02:00