xml: tag_name serialization in untagged fields

This commit is contained in:
Lennart
2024-12-28 12:39:27 +01:00
parent a3a633f74f
commit 759bb1f1be
3 changed files with 65 additions and 4 deletions

View File

@@ -50,6 +50,16 @@ impl_value_parse!(u64);
impl_value_parse!(isize);
impl_value_parse!(usize);
impl Value for &str {
fn serialize(&self) -> String {
self.to_string()
}
fn deserialize(val: &str) -> Result<Self, XmlDeError> {
Err(XmlDeError::Other("TODO: Handle this error".to_owned()))
}
}
impl<T: Value> XmlDeserialize for T {
fn deserialize<R: BufRead>(
reader: &mut quick_xml::NsReader<R>,