NAME

Perinci::To::DocBase - Base class for class that generates documentation from Rinci metadata

VERSION

version 0.06

DESCRIPTION

DocBase is the base class for classes that produce documentation from Rinci metadata. It provides i18n class using Locale::Maketext (Perinci::To::DocBase::I18N) and you can access the language handle at $self->_lh.

To generate a documentation, first you provide a list of section names in sections. Then you run generate(), which will call parse_SECTION and gen_SECTION methods for each section consecutively. parse_* is supposed to parse information from the metadata into a form readily usable in $self->_parse hash. gen_* is supposed to generate the actual section in the final documentation format, by calling add_lines to add text. The base class provides many of the parse_* methods but provides none of the gen_* methods, which must be supplied by subclasses like Perinci::To::Text, Perinci::To::POD, Perinci::To::HTML. Finally all the added lines is concatenated together and returned.

AUTHOR

Steven Haryanto <stevenharyanto@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2012 by Steven Haryanto.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.