OODoc::Format - base class for all OODoc formatters
OODoc::Format is an OODoc::Object OODoc::Format is extended by OODoc::Format::Html OODoc::Format::Pod
# Never instantiated directly.
A formater produces manual pages in some way or an other which contain (parts of) the module documentation. Each formatter class is based on this OODoc::Format class, which should not be instantiated directly. By far most users will never explicitly create a formatter by themselves: it is created implicitly when OODoc::create() is called on a OODoc object.
Currently available formatters:
OODoc::Format::Pod
Simple formatter, which has the layout of the produced POD manual pages hard-coded in it's body. The only way to adapt the structure of the pages is by extending the class, and thereby overrule some of the methods which produce the text. Not much of a problem for experienced Object Oriented programmers.
OODoc::Format::Pod2
This formatter uses the same methods to generate the manual page as defined by OODoc::Format::Pod, but the general layout of the page can be configured using templates.
You have to install Bundle::Template::Magic to use this feature.
OODoc::Format::Pod3
The whole formatter, implemented as template in OODoc::Template, a very light weighted template system.
You have to install OODoc::Template to use this feature.
OODoc::Format::Html
Produce HTML by filling in templates. This module requires Bundle::Template::Magic and the ability to run cgi scripts.
Extends "DESCRIPTION" in OODoc::Object.
Extends "OVERLOADED" in OODoc::Object.
Extends "METHODS" in OODoc::Object.
Extends "Constructors" in OODoc::Object.
-Option --Default manifest undef project <required> version <required> workdir <required>
The short name of this project (module), set by OODoc::new(project).
Many manual pages will contain the version of the project. This can be any STRING, although blanks are not advised.
The DIRECTORY where the output will be placed. If it does not exist, it will be created for you.
Extends "Inheritance knowledge" in OODoc::Object.
Inherited, see "Inheritance knowledge" in OODoc::Object
Returns the OODoc::Manifest object which maintains the names of created files.
Returns the name of this project.
Returns the version string of this project. This version may contains any character, so should be handled with care.
Returns the name of the work directory: the top location for all the output files.
Takes the STRING and cleans it up to be in the right format for the current formatter. The cleaning up is parser dependent, and therefore the parser of the manual is addressed to do the work.
-Option --Default append undef format_options [] manual <required> project <required> template undef
An ARRAY which contains a list of options which are the defaults for formatting a chapter.
The manual to be formatted.
The name of this project, which will appear on many pages.
Some formatters support templates to descibe the output of the pages. The valid values for this option differs per formatter.
Create other pages which come with the set of formatted manuals. What the contents of these pages is depends on the formatter. Some formatters simply ignore the functionality of this method as a whole: they do not support data-files which are not manuals.
-Option --Default process undef source undef
Selects files to be processed from the source directory. Other files are copied without modification. What happens with the selected files is formatter dependent.
The location of the DIRECTORY which contains files which are part of the produced set of documentation, but not copied per manual page but only once.
You can pass all %options about formatting to this method. They will passed to the related methods. So: the list of options you can pass here is much longer: the combination of everything possible for all show* methods.
-Option --Default chapter <required> manual <required> output <required> show_inherited_chapters 'REFER' show_inherited_sections 'REFER' show_inherited_subsections 'REFER'
REFER means that inherited sections are simply listed as reference to the manual page which describes it.
-Option --Default examples <required> manual <required> output <required>
-Option --Default default <required> manual <required> option <required> output <required>
-Option --Default manual <required> options <required> output <required>
The options shown are not the %options passed as argument, but the options which belong to the subroutine being displayed.
-Option --Default manual <required> options <required> show_described_options 'EXPAND' show_inherited_options 'USE'
-Option --Default show_chapter_examples 'EXPAND'
The chapter examples are all examples which are not subroutine related: examples which come at the end of a chapter, section, or subsection.
-Option --Default last 0 manual <required> output <selected filehandle> show_described_options 'EXPAND' show_diagnostics 'NO' show_examples 'EXPAND' show_inherited_options 'USE' show_option_table 'ALL' show_sub_description 'DESCRIBED' show_subroutine 'EXPAND' subroutine <required>
Diagnostics (error and warning messages) are defined per subroutine, but are usually not listed with the subroutine. The POD formatter's default behavior, for instance, puts them all in a separate DIAGNOSTICS chapter per manual page.
Included the description of the use of the subroutines, which comes before the options are being explained. NO will cause the description to be ignored, DESCRIBED means that only text which was written in the manual-page at hand is included, REFER means that a reference to inherited documentation is made, and with ALL the inherited texts are expanded into this file as well.
NO
DESCRIBED
REFER
ALL
-Option --Default manual <required> output <required> subroutine <required>
-Option --Default last 0 manual <required> output <required> subroutine <required>
-Option --Default manual <required> output <selected filehandle> show_described_options 'EXPAND' show_described_subs 'EXPAND' show_diagnostics 'NO' show_examples 'EXPAND' show_inherited_options 'USE' show_inherited_subs 'USE' show_option_table 'ALL' show_subs_index 'NO' subroutines []
Extends "Commonly used functions" in OODoc::Object.
Inherited, see "Commonly used functions" in OODoc::Object
Extends "Manual Repository" in OODoc::Object.
Inherited, see "Manual Repository" in OODoc::Object
A formatter was created without a name specified for the project at hand. This should be passed with new(project).
A call to addManual() expects a new manual object (a OODoc::Manual), however an incompatible thing was passed. Usually, intended was a call to manualsForPackage() or mainManual().
The formatter has to know where the output can be written. This directory must be provided via new(workdir), but was not specified.
This module is part of OODoc distribution version 2.02, built on December 08, 2021. Website: http://perl.overmeer.net/oodoc/
Copyrights 2003-2021 by [Mark Overmeer]. For other contributors see ChangeLog.
This program is free software; you can redistribute it and/or modify it under the Artistic license. See http://dev.perl.org/licenses/artistic.html
To install OODoc, copy and paste the appropriate command in to your terminal.
cpanm
cpanm OODoc
CPAN shell
perl -MCPAN -e shell install OODoc
For more information on module installation, please visit the detailed CPAN module installation guide.