Enum quickxml_to_serde::NullValue
source · pub enum NullValue {
Ignore,
Null,
EmptyObject,
}
Expand description
Defines how empty elements like <x />
should be handled.
Ignore
-> exclude from JSON, Null
-> "x":null
, EmptyObject -> "x":{}
.
EmptyObject
is the default option and is how it was handled prior to v.0.4
Using Ignore
on an XML document with an empty root element falls back to Null
option.
E.g. both <a><x/></a>
and <a/>
are converted into {"a":null}
.
Variants§
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for NullValue
impl Send for NullValue
impl Sync for NullValue
impl Unpin for NullValue
impl UnwindSafe for NullValue
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more