docx_reader/documents/elements/
table_layout.rs

1use serde::{Serialize, Serializer};
2
3use crate::types::*;
4
5#[derive(Debug, Clone, PartialEq)]
6pub struct TableLayout {
7	layout_type: TableLayoutType,
8}
9
10impl TableLayout {
11	pub fn new(t: TableLayoutType) -> TableLayout {
12		TableLayout { layout_type: t }
13	}
14}
15
16impl Serialize for TableLayout {
17	fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
18	where
19		S: Serializer,
20	{
21		serializer.serialize_str(&self.layout_type.to_string())
22	}
23}