pub trait FormatWriter {
// Required method
fn write_changelog(
&mut self,
options: &Clog,
section_map: &SectionMap,
) -> Result<()>;
}
Expand description
A trait that allows writing the results of a clog
run which can then be
written in an arbitrary format. The single required function
write_changelog()
accepts a clog::SectionMap
which can be thought of
similiar to a clog
“AST” of sorts.
clog
provides two default implementors of this traint,
clog::fmt::MarkdownWriter
and clog::fmt::JsonWriter
for writing Markdown
and JSON respectively
Required Methods§
Sourcefn write_changelog(
&mut self,
options: &Clog,
section_map: &SectionMap,
) -> Result<()>
fn write_changelog( &mut self, options: &Clog, section_map: &SectionMap, ) -> Result<()>
Writes a changelog from a given clog::SectionMap
which can be thought
of as an “AST” of sorts