1use super::*;
2
3#[derive(Clone, Data, Debug, Default, Deserialize, New, PartialEq, Serialize)]
5pub struct PackedPageBody {
6 #[serde(default, skip_serializing_if = "String::is_empty")]
8 pub(crate) markdown_body: String,
9 #[serde(default, skip_serializing_if = "Vec::is_empty")]
11 pub(crate) blocks: Vec<DocBlock>,
12}
13
14#[derive(Clone, Debug, Eq, Getter, New, PartialEq)]
16pub struct PackedSiteBundle {
17 pub(crate) shell_json: String,
19 pub(crate) compressed_bodies: Vec<u8>,
21}
22
23#[derive(Clone, Data, Debug, Default)]
25pub(crate) struct CodecBitWriter {
26 #[get(pub(crate))]
28 #[get_mut(pub(crate))]
29 #[set(pub(crate))]
30 pub(crate) bytes: Vec<u8>,
31 #[get(pub(crate), type(copy))]
33 #[get_mut(pub(crate))]
34 #[set(pub(crate))]
35 pub(crate) bit_buf: u64,
36 #[get(pub(crate), type(copy))]
38 #[get_mut(pub(crate))]
39 #[set(pub(crate))]
40 pub(crate) bit_count: u32,
41}
42
43#[derive(Clone, Data, Debug)]
45pub(crate) struct CodecBitReader<'a> {
46 #[get(pub(crate), type(copy))]
48 #[get_mut(skip)]
49 #[set(skip)]
50 pub(crate) data: &'a [u8],
51 #[get(pub(crate), type(copy))]
53 #[get_mut(pub(crate))]
54 #[set(pub(crate))]
55 pub(crate) cursor: usize,
56 #[get(pub(crate), type(copy))]
58 #[get_mut(pub(crate))]
59 #[set(pub(crate))]
60 pub(crate) bit_buf: u64,
61 #[get(pub(crate), type(copy))]
63 #[get_mut(pub(crate))]
64 #[set(pub(crate))]
65 pub(crate) bit_count: u32,
66}