NAME
OODoc::Format - base class for all OODoc formatters
INHERITANCE
OODoc::Format
is a OODoc::Object
OODoc::Format is extended by
OODoc::Format::Pod
SYNOPSIS
# Never instantiated directly.
DESCRIPTION
A formater produces manual pages in some way or an other which contain (parts of) the module documentation.
METHODS
$obj->cleanup(MANUAL, STRING)
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.
$obj->createIndexPages(OPTIONS)
Option Defined in Default
manifest C<undef>
. manifest MANIFEST
$obj->createPackageManual(OPTIONS)
Option Defined in Default
manifest C<undef>
manuals []
workdir <required>
. manifest MANIFEST
. manuals ARRAY
All manuals which belong to the same package description. This ARRAY is usually longer than one when the package uses autoloading to dynamically load code on demand.
. workdir DIRECTORY
$obj->showChapter(OPTIONS)
You can pass all options about formatting to this method. They will passed to the related methods.
Option Defined in Default
chapter <required>
output <required>
show_chapter_examples <true>
. chapter CHAPTER
. output FILE
. show_chapter_examples BOOLEAN
$obj->showExamples(OPTIONS)
Option Defined in Default
examples <required>
manual <required>
output <required>
. examples ARRAY
. manual MANUAL
. output FILE
$obj->showOptionExpand(OPTIONS)
Option Defined in Default
default <required>
manual <required>
option <required>
output <required>
. default OBJECT
. manual OBJECT
. option OBJECT
. output FILE
$obj->showOptionTable(OPTIONS)
Option Defined in Default
manual <required>
options <required>
output <required>
. manual OBJECT
. options ARRAY
. output FILE
$obj->showOptionUse(OPTIONS)
Option Defined in Default
default <required>
manual <required>
option <required>
output <required>
. default OBJECT
. manual OBJECT
. option OBJECT
. output FILE
$obj->showOptionalChapter(NAME, OPTIONS)
$obj->showOptions(OPTIONS)
The options shown are not the OPTIONS passed as argument, but the options which belong to the subroutine being displayed.
Option Defined in Default
manual <required>
options <required>
show_described_options 'EXPAND'
show_inherited_options 'USE'
. manual OBJECT
. options ARRAY
. show_described_options 'NO'|'LIST'|'USE'|'EXPAND'
. show_inherited_options 'NO'|'LIST'|'USE'|'EXPAND'
$obj->showRequiredChapter(NAME, OPTIONS)
$obj->showSubroutine((@))
Option Defined in 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>
. last BOOLEAN
. manual MANUAL
. output FILE
. show_described_options 'NO'|'LIST'|'USE'|'EXPAND'
. show_diagnostics 'NO'|'EXPAND'
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.
. show_examples 'NO'|'EXPAND'
. show_inherited_options 'NO'|'LIST'|'USE'|'EXPAND'
. show_option_table 'NO'|'INHERITED'|'DESCRIBED'|'ALL'
. show_sub_description 'NO'|'DESCRIBED'|'REFER'|'ALL'
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.
. show_subroutine 'NO'|'NAMES'|'USE'|'EXPAND'
. subroutine OBJECT
$obj->showSubroutineDescription(OPTIONS)
Option Defined in Default
manual <required>
output <required>
subroutine <required>
. manual OBJECT
. output FILE
. subroutine OBJECT
$obj->showSubroutineName(OPTIONS)
Option Defined in Default
last 0
manual <required>
output <required>
subroutine <required>
. last BOOLEAN
. manual OBJECT
. output FILE
. subroutine OBJECT
$obj->showSubroutineUse(OPTIONS)
Option Defined in Default
manual <required>
output <required>
subroutine <required>
. manual OBJECT
. output FILE
. subroutine OBJECT
$obj->showSubroutines(OPTIONS)
Option Defined in Default
manual <required>
output <selected filehandle>
show_described_options 'EXPAND'
show_described_subs 'EXPAND'
show_inherited_options 'USE'
show_inherited_subs 'USE'
show_option_table 'ALL'
show_subs_index 'NO'
subroutines []
. manual MANUAL
. output FILE
. show_described_options 'NO'|'LIST'|'USE'|'EXPAND'
. show_described_subs 'NO'|'NAMES'|'USE'|'EXPAND'
. show_inherited_options 'NO'|'LIST'|'USE'|'EXPAND'
. show_inherited_subs 'NO'|'NAMES'|'USE'|'EXPAND'
. show_option_table 'NO'|'DESCRIBED'|'INHERITED'|'ALL'
. show_subs_index 'NO'|'NAMES'|'USE'
. subroutines ARRAY
Initiation
OODoc::Format->new(OPTIONS)
Inheritance
$obj->extends([OBJECT])
Commonly used functions
$obj->filenameToPackage(FILENAME)
OODoc::Format->filenameToPackage(FILENAME)
$obj->mergeObjects(OPTIONS)
$obj->mkdirhier(DIRECTORY)
OODoc::Format->mkdirhier(DIRECTORY)
$obj->unique
Manual database
All manuals can be reached everywhere in the program: it is a global collection.
$obj->addManual(MANUAL)
$obj->mainManual(NAME)
$obj->manuals
$obj->manualsForPackage(NAME)
$obj->packageNames
DIAGNOSTICS
Error: manual definition requires manual object
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().
Warning: missing required chapter $name in $manual
Warning: order conflict "$take" before "$insert" in $file line $number
The order of the objects in a sub-class shall be the same as that of the super class, otherwise the result of merging of the information received from both classes is undertermined.
Warning: unknown subroutine type $type for $name in $manual