pub trait Xml: Sized {
// Required method
fn serialize_xml(&self, fmt: &mut Formatter<'_>) -> Result;
// Provided methods
fn xml(&self) -> String { ... }
fn display<'a>(&'a self) -> Display<'a, Self> { ... }
}Expand description
A trait the allows you to serialize data to xml
Required Methods§
Sourcefn serialize_xml(&self, fmt: &mut Formatter<'_>) -> Result
fn serialize_xml(&self, fmt: &mut Formatter<'_>) -> Result
serialize xml to a formatter
Provided Methods§
Sourcefn display<'a>(&'a self) -> Display<'a, Self>
fn display<'a>(&'a self) -> Display<'a, Self>
serialize xml via std::fmt::Display trait
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.