1Pod::Weaver(3) User Contributed Perl Documentation Pod::Weaver(3)
2
3
4
6 Pod::Weaver - weave together a Pod document from an outline
7
9 version 4.017
10
12 my $weaver = Pod::Weaver->new_with_default_config;
13
14 my $document = $weaver->weave_document({
15 pod_document => $pod_elemental_document,
16 ppi_document => $ppi_document,
17
18 license => $software_license,
19 version => $version_string,
20 authors => \@author_names,
21 })
22
24 Pod::Weaver is a system for building Pod documents from templates. It
25 doesn't perform simple text substitution, but instead builds a
26 Pod::Elemental::Document. Its plugins sketch out a series of sections
27 that will be produced based on an existing Pod document or other
28 provided information.
29
31 logger
32 This attribute stores the logger, which must provide a log method. The
33 weaver's log method delegates to the logger's log method.
34
35 plugins
36 This attribute is an arrayref of objects that can perform the
37 Pod::Weaver::Role::Plugin role. In general, its contents are found
38 through the "plugins_with" method.
39
41 plugins_with
42 my $plugins_array_ref = $weaver->plugins_with('-Section');
43
44 This method will return an arrayref of plugins that perform the given
45 role, in the order of their registration. If the role name begins with
46 a hyphen, the method will prepend "Pod::Weaver::Role::".
47
48 weave_document
49 my $document = $weaver->weave_document(\%input);
50
51 This is the most important method in Pod::Weaver. Given a set of input
52 parameters, it will weave a new document. Different section plugins
53 will expect different input parameters to be present, but some common
54 ones include:
55
56 pod_document - a Pod::Elemental::Document for the original Pod document
57 ppi_document - a PPI document for the source of the module being documented
58 license - a Software::License object for the source module's license
59 version - a version (string) to use in produced documentation
60
61 The "pod_document" should have gone through a Pod5 transformer, and
62 should probably have had its "=head1" elements nested.
63
64 The method will return a new Pod::Elemental::Document. The input
65 documents may be destructively altered during the weaving process. If
66 they should be untouched, pass in copies.
67
68 new_with_default_config
69 This method returns a new Pod::Weaver with a stock configuration by
70 using only Pod::Weaver::PluginBundle::Default.
71
73 Ricardo SIGNES <rjbs@cpan.org>
74
76 • Alex Peters <lxp@cpan.org>
77
78 • Apocalypse <perl@0ne.us>
79
80 • Blabos de Blebe <blabos@cpan.org>
81
82 • Caleb Cushing <xenoterracide@gmail.com>
83
84 • Christian Walde <walde.christian@googlemail.com>
85
86 • Christopher J. Madsen <perl@cjmweb.net>
87
88 • Chris Weyl <cweyl@alumni.drew.edu>
89
90 • Dave Houston <dave.houston@gmail.com>
91
92 • Dave Rolsky <autarch@urth.org>
93
94 • David E. Wheeler <david@justatheory.com>
95
96 • David Golden <dagolden@cpan.org>
97
98 • David Miguel Susano Pinto <carandraug+dev@gmail.com>
99
100 • David Zurborg <post@david-zurb.org>
101
102 • Doug Bell <doug@preaction.me>
103
104 • Florian Ragwitz <rafl@debian.org>
105
106 • Jonathan "Duke" Leto <jonathan@leto.net>
107
108 • Joshua Keroes <joshua.keroes@integratelecom.com>
109
110 • Karen Etheridge <ether@cpan.org>
111
112 • Kent Fredric <kentfredric@gmail.com>
113
114 • Kivanc Yazan <kyzn@cpan.org>
115
116 • Marcel Gruenauer <hanekomu@gmail.com>
117
118 • Randy Stauner <randy@magnificent-tears.com>
119
120 • Ricardo Signes <rjbs@semiotic.systems>
121
122 • Sam Graham <git@illusori.co.uk>
123
124 • Shlomi Fish <shlomif@shlomifish.org>
125
127 This software is copyright (c) 2021 by Ricardo SIGNES.
128
129 This is free software; you can redistribute it and/or modify it under
130 the same terms as the Perl 5 programming language system itself.
131
132
133
134perl v5.32.1 2021-04-19 Pod::Weaver(3)