Trait sise::SerializeStyle
source · pub trait SerializeStyle<'a> {
fn begin(&mut self, output: &mut String);
fn begin_list(&mut self, list_node: &'a Node, output: &mut String);
fn end_list(&mut self, output: &mut String);
fn atom(&mut self, atom_node: &'a Node, output: &mut String);
fn finish(&mut self, output: &mut String);
}
Expand description
Trait that allows to implement serialization styles.
Required Methods§
sourcefn begin(&mut self, output: &mut String)
fn begin(&mut self, output: &mut String)
Called at the beginning of the serialization (nothing has been writen to output yet).
sourcefn begin_list(&mut self, list_node: &'a Node, output: &mut String)
fn begin_list(&mut self, list_node: &'a Node, output: &mut String)
Called at the beginning of a list (before writing (
to output
)
sourcefn end_list(&mut self, output: &mut String)
fn end_list(&mut self, output: &mut String)
Called at the end of a list (before writing )
to output
)