pub enum NamespaceSerialization {
None,
Local,
Global,
Dynamic,
}Expand description
Defines how the QuickXmlSerializeRenderStep will serialize the different
namespaces of the elements and attributes.
Variants§
None
Do not serialize any namespace definitions.
Local
All namespace definitions are added to the local element if they are not already in scope.
Global
All namespace definitions are serialized to the root element.
Dynamic
Namespace definitions are collected at runtime by traversing the value
tree via the CollectNamespaces
trait, and only the namespaces that are actually needed by the current
value are written to the root element.
This requires the QuickXmlCollectNamespacesRenderStep
to be added to the renderer pipeline as well, so that CollectNamespaces
is implemented for all generated types.
Implementations§
Source§impl NamespaceSerialization
impl NamespaceSerialization
Sourcepub fn is_none(&self) -> bool
pub fn is_none(&self) -> bool
Returns true if this is NamespaceSerialization::None, false otherwise.
Sourcepub fn is_some(&self) -> bool
pub fn is_some(&self) -> bool
Returns true if this is NamespaceSerialization::Local,
NamespaceSerialization::Global, or NamespaceSerialization::Dynamic,
false otherwise.
Trait Implementations§
Source§impl Clone for NamespaceSerialization
impl Clone for NamespaceSerialization
Source§fn clone(&self) -> NamespaceSerialization
fn clone(&self) -> NamespaceSerialization
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for NamespaceSerialization
impl Debug for NamespaceSerialization
Source§impl PartialEq for NamespaceSerialization
impl PartialEq for NamespaceSerialization
impl Copy for NamespaceSerialization
impl Eq for NamespaceSerialization
impl StructuralPartialEq for NamespaceSerialization
Auto Trait Implementations§
impl Freeze for NamespaceSerialization
impl RefUnwindSafe for NamespaceSerialization
impl Send for NamespaceSerialization
impl Sync for NamespaceSerialization
impl Unpin for NamespaceSerialization
impl UnsafeUnpin for NamespaceSerialization
impl UnwindSafe for NamespaceSerialization
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.