Trait genco::Custom [] [src]

pub trait Custom where
    Self: Sized
{ type Extra: Default; fn format(
        &self,
        _out: &mut Formatter,
        _extra: &mut Self::Extra,
        _level: usize
    ) -> Result { ... }
fn quote_string(out: &mut Formatter, input: &str) -> Result { ... }
fn write_file<'el>(
        tokens: Tokens<'el, Self>,
        out: &mut Formatter,
        extra: &mut Self::Extra,
        level: usize
    ) -> Result { ... } }

Trait that must be implemented by custom elements.

Associated Types

Extra data associated with building a formatting element.

Provided Methods

Format the custom element.

Performing quoting according to convention set by custom element.

Write a file according to convention by custom element.

Implementations on Foreign Types

impl Custom for ()
[src]

Dummy implementation for unit.

[src]

[src]

[src]

Implementors