docx_reader/documents/
numberings.rsuse super::*;
use serde::Serialize;
#[derive(Debug, Clone, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct Numberings {
pub abstract_nums: Vec<AbstractNumbering>,
pub numberings: Vec<Numbering>,
}
impl Numberings {
pub fn new() -> Self {
Default::default()
}
pub fn add_abstract_numbering(mut self, n: AbstractNumbering) -> Self {
self.abstract_nums.push(n);
self
}
pub fn add_numbering(mut self, n: Numbering) -> Self {
self.numberings.push(n);
self
}
}
impl Default for Numberings {
fn default() -> Self {
Self {
abstract_nums: vec![],
numberings: vec![],
}
}
}