[][src]Struct xmlwriter::Options

pub struct Options {
    pub use_single_quote: bool,
    pub indent: Indent,
    pub attributes_indent: Indent,
}

An XML writing options.

Fields

use_single_quote: bool

Use single quote marks instead of double quote.

Examples

Before:

<rect fill="red"/>

After:

<rect fill='red'/>

Default: disabled

indent: Indent

Set XML nodes indention.

Examples

Indent::None Before:

<svg>
    <rect fill="red"/>
</svg>

After:

<svg><rect fill="red"/></svg>

Default: 4 spaces

attributes_indent: Indent

Set XML attributes indention.

Examples

Indent::Spaces(2)

Before:

<svg>
    <rect fill="red" stroke="black"/>
</svg>

After:

<svg>
    <rect
      fill="red"
      stroke="black"/>
</svg>

Default: None

Trait Implementations

impl Clone for Options[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Default for Options[src]

impl Copy for Options[src]

impl Debug for Options[src]

Auto Trait Implementations

impl Sync for Options

impl Send for Options

impl Unpin for Options

impl RefUnwindSafe for Options

impl UnwindSafe for Options

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]