Lines Matching full:pod

8 #pod =head1 DESCRIPTION
9 #pod
10 #pod A CPAN::Meta::Prereqs object represents the prerequisites for a CPAN
11 #pod distribution or one of its optional features. Each set of prereqs is
12 #pod organized by phase and type, as described in L<CPAN::Meta::Prereqs>.
13 #pod
14 #pod =cut
20 #pod =method new
21 #pod
22 #pod my $prereq = CPAN::Meta::Prereqs->new( \%prereq_spec );
23 #pod
24 #pod This method returns a new set of Prereqs. The input should look like the
25 #pod contents of the C<prereqs> field described in L<CPAN::Meta::Spec>, meaning
26 #pod something more or less like this:
27 #pod
28 #pod my $prereq = CPAN::Meta::Prereqs->new({
29 #pod runtime => {
30 #pod requires => {
31 #pod 'Some::Module' => '1.234',
32 #pod ...,
33 #pod },
34 #pod ...,
35 #pod },
36 #pod ...,
37 #pod });
38 #pod
39 #pod You can also construct an empty set of prereqs with:
40 #pod
41 #pod my $prereqs = CPAN::Meta::Prereqs->new;
42 #pod
43 #pod This empty set of prereqs is useful for accumulating new prereqs before finally
44 #pod dumping the whole set into a structure or string.
45 #pod
46 #pod =cut
83 #pod =method requirements_for
84 #pod
85 #pod my $requirements = $prereqs->requirements_for( $phase, $type );
86 #pod
87 #pod This method returns a L<CPAN::Meta::Requirements> object for the given
88 #pod phase/type combination. If no prerequisites are registered for that
89 #pod combination, a new CPAN::Meta::Requirements object will be returned, and it may
90 #pod be added to as needed.
91 #pod
92 #pod If C<$phase> or C<$type> are undefined or otherwise invalid, an exception will
93 #pod be raised.
94 #pod
95 #pod =cut
118 #pod =method phases
119 #pod
120 #pod my @phases = $prereqs->phases;
121 #pod
122 #pod This method returns the list of all phases currently populated in the prereqs
123 #pod object, suitable for iterating.
124 #pod
125 #pod =cut
134 #pod =method types_in
135 #pod
136 #pod my @runtime_types = $prereqs->types_in('runtime');
137 #pod
138 #pod This method returns the list of all types currently populated in the prereqs
139 #pod object for the provided phase, suitable for iterating.
140 #pod
141 #pod =cut
152 #pod =method with_merged_prereqs
153 #pod
154 #pod my $new_prereqs = $prereqs->with_merged_prereqs( $other_prereqs );
155 #pod
156 #pod my $new_prereqs = $prereqs->with_merged_prereqs( \@other_prereqs );
157 #pod
158 #pod This method returns a new CPAN::Meta::Prereqs objects in which all the
159 #pod other prerequisites given are merged into the current set. This is primarily
160 #pod provided for combining a distribution's core prereqs with the prereqs of one of
161 #pod its optional features.
162 #pod
163 #pod The new prereqs object has no ties to the originals, and altering it further
164 #pod will not alter them.
165 #pod
166 #pod =cut
198 #pod =method merged_requirements
199 #pod
200 #pod my $new_reqs = $prereqs->merged_requirements( \@phases, \@types );
201 #pod my $new_reqs = $prereqs->merged_requirements( \@phases );
202 #pod my $new_reqs = $prereqs->merged_requirements();
203 #pod
204 #pod This method joins together all requirements across a number of phases
205 #pod and types into a new L<CPAN::Meta::Requirements> object. If arguments
206 #pod are omitted, it defaults to "runtime", "build" and "test" for phases
207 #pod and "requires" and "recommends" for types.
208 #pod
209 #pod =cut
241 #pod =method as_string_hash
242 #pod
243 #pod This method returns a hashref containing structures suitable for dumping into a
244 #pod distmeta data structure. It is made up of hashes and strings, only; there will
245 #pod be no Prereqs, CPAN::Meta::Requirements, or C<version> objects inside it.
246 #pod
247 #pod =cut
266 #pod =method is_finalized
267 #pod
268 #pod This method returns true if the set of prereqs has been marked "finalized," and
269 #pod cannot be altered.
270 #pod
271 #pod =cut
275 #pod =method finalize
276 #pod
277 #pod Calling C<finalize> on a Prereqs object will close it for further modification.
278 #pod Attempting to make any changes that would actually alter the prereqs will
279 #pod result in an exception being thrown.
280 #pod
281 #pod =cut
293 #pod =method clone
294 #pod
295 #pod my $cloned_prereqs = $prereqs->clone;
296 #pod
297 #pod This method returns a Prereqs object that is identical to the original object,
298 #pod but can be altered without affecting the original object. Finalization does
299 #pod not survive cloning, meaning that you may clone a finalized set of prereqs and
300 #pod then modify the clone.
301 #pod
302 #pod =cut
319 =pod