serde-xml-rs
serde-xml-rs copied to clipboard
xml-rs based deserializer for Serde (compatible with 1.0+)
I have the following struct. ``` #[derive(Serialize, Deserialize, Debug)] pub struct InitiateTransactionResponse { #[serde(rename="Error", default)] pub errors: Vec, #[serde(rename="TransactionStatusCode", default)] pub transaction_status_code: Option, #[serde(rename="Transaction", default)] pub transaction: Vec } ```...
Required detail discussion, my vision is for #[serde(rename = "$xml:x")] - $xml:tag:value or $xml:value for tag Value - $xml:ns:name for NS Value - $xml:attr:name for Attr Value Also somethink like...
The following XML data result in "Error: duplicate field `fragments`" ` ` **input struct is:** #[derive(Debug, Deserialize)] pub struct OutputMessage { pub timezone: String, pub id: String, pub repeat: String,...
It appears that serde-xml-rs cannot be used to deserialize into borrowed strings. This is rather annoying. Example: ```rust #[macro_use] extern crate serde_derive; // 1.0 extern crate serde; // 1.0 extern...
I have data which can look like either: ```xml ``` or ```xml aaabbbbbbbcc ``` And, as far as I can see, this is not (yet) possible to deserialize. With the...
Hi! I'm trying to capture some data from an xml fragment that includes both a child node, and a text node, but the parser seems to be having trouble. Looks...
How to serialise attributes on XML items ? I d'ont see anything for that. Any suggestion ?
What rust structure shall I go for the following situation? `` Flugzeug Airplane Triangle `` I could not find a suitable example for describing a field with a value like...
I'm currently, as part of trying to learn how serde-xml-rs works, trying to parse [Senate roll call data](https://www.senate.gov/legislative/LIS/roll_call_lists/vote_menu_115_1.xml). When learning new XML libraries this is my go-to source as it...
```rust #[derive(Default, Debug, Clone, PartialEq, Serialize)] pub struct Message, pub content: T, } #[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] pub struct ArtsCommonHeader