serde-capture

Crates.ioserde-capture
lib.rsserde-capture
version0.1.0
sourcesrc
created_at2019-11-14 21:35:12.636003
updated_at2019-11-14 21:35:12.636003
description'Skip' deserialisation, but extract some, and retain the rest for later
homepage
repositoryhttps://github.com/FauxFaux/serde-capture
max_upload_size
id181325
size4,287
Chris West (FauxFaux)

documentation

README

serde-capture

Capture some part of a document during deserialisation, and store it serialised, instead of as a structure. This might use less memory.

This provides a:

pub struct CaptureJson<T> {
    pub inner: T,
    pub bytes: Box<[u8]>,
}

... which you can embed in your structure:

struct Doc {
    foo: Vec<CaptureJson<Nothing>>,
}

... which should be smaller than Vec<Value>, but with significantly slower access.

Commit count: 5

cargo fmt