.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.29) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Dist::Zilla::Role::MetaProvider::Provider 3pm" .TH Dist::Zilla::Role::MetaProvider::Provider 3pm "2016-08-08" "perl v5.22.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Dist::Zilla::Role::MetaProvider::Provider \- A Role for Metadata providers specific to the 'provider' key. .SH "VERSION" .IX Header "VERSION" version 2.002003 .SH "PUBLIC METHODS" .IX Header "PUBLIC METHODS" .ie n .SS """metadata""" .el .SS "\f(CWmetadata\fP" .IX Subsection "metadata" Fulfills the requirement of Dist::Zilla::Role::MetaProvider by processing results returned from \f(CW\*(C`$self\->provides\*(C'\fR. .SH "ATTRIBUTES / PARAMETERS" .IX Header "ATTRIBUTES / PARAMETERS" .ie n .SS """inherit_version""" .el .SS "\f(CWinherit_version\fP" .IX Subsection "inherit_version" This dictates how to report versions. .PP \fIvalues\fR .IX Subsection "values" .IP "\(bu" 4 Set to \*(L"1\*(R" \fB[default]\fR The version defined by Dist::Zilla is the authority, and all versions discovered in packages are ignored. .IP "\(bu" 4 Set to \*(L"0\*(R" The version defined in the discovered class is the authority, and it is copied to the provides metadata. .PP ( To use this feature in a performing class, see \*(L"_resolve_version\*(R" ) .ie n .SS """inherit_missing""" .el .SS "\f(CWinherit_missing\fP" .IX Subsection "inherit_missing" This dictates how to react when a class is discovered but a version is not specified. .PP \fIvalues\fR .IX Subsection "values" .IP "\(bu" 4 Set to \*(L"1\*(R" \fB[default]\fR \&\f(CW\*(C`dist.ini\*(C'\fR's version turns up in the final metadata. .IP "\(bu" 4 Set to \*(L"0\*(R". A \f(CW\*(C`provide\*(C'\fR turns up in the final metadata without a version, which is permissible. .PP ( To use this feature in a performing class, see \*(L"_resolve_version\*(R" ) .ie n .SS """meta_noindex""" .el .SS "\f(CWmeta_noindex\fP" .IX Subsection "meta_noindex" This dictates how to behave when a discovered class is also present in the \f(CW\*(C`no_index\*(C'\fR \s-1META\s0 field. .PP \fIvalues\fR .IX Subsection "values" .IP "\(bu" 4 Set to \*(L"0\*(R" \fB[default]\fR .Sp \&\f(CW\*(C`no_index\*(C'\fR \s-1META\s0 field will be ignored .IP "\(bu" 4 Set to \*(L"1\*(R" .Sp \&\f(CW\*(C`no_index\*(C'\fR \s-1META\s0 field will be recognised and things found in it will cause respective packages to not be provided in the metadata. .SH "PERFORMS ROLES" .IX Header "PERFORMS ROLES" .SS "MetaProvider" .IX Subsection "MetaProvider" Dist::Zilla::Role::MetaProvider .SH "REQUIRED METHODS FOR PERFORMING ROLES" .IX Header "REQUIRED METHODS FOR PERFORMING ROLES" .ie n .SS """provides""" .el .SS "\f(CWprovides\fP" .IX Subsection "provides" Must return an array full of Dist::Zilla::MetaProvides::ProvideRecord instances. .SH "PRIVATE METHODS" .IX Header "PRIVATE METHODS" .ie n .SS """_resolve_version""" .el .SS "\f(CW_resolve_version\fP" .IX Subsection "_resolve_version" This is a utility method to make performing classes life easier in adhering to user requirements. .PP .Vb 4 \& my $params = { \& file => $somefile , \& $self\->_resolve_version( $version ); \& } .Ve .PP is the suggested use. .PP Returns either an empty list, or a list with \f(CW\*(C`(\*(Aqversion\*(Aq, $version )\*(C'\fR; .PP This is so \f(CW\*(C`{ version => undef }\*(C'\fR does not occur in the \s-1YAML.\s0 .ie n .SS """_try_regen_metadata""" .el .SS "\f(CW_try_regen_metadata\fP" .IX Subsection "_try_regen_metadata" This is a nasty hack really, to work around the way \f(CW\*(C`Dist::Zilla\*(C'\fR handles metaproviders, which result in meta-data being inaccessible to metadata Plugins. .PP .Vb 1 \& my $meta = $object\->_try_regen_metadata() .Ve .PP This at present returns metadata provided by \f(CW\*(C`MetaNoIndex\*(C'\fR ( if present ) but will be expanded as needed. .PP If you have a module you think should be in this list, contact me, or file a bug, I'll do my best ☺ .ie n .SS """_apply_meta_noindex""" .el .SS "\f(CW_apply_meta_noindex\fP" .IX Subsection "_apply_meta_noindex" This is a utility method to make performing classes life easier in skipping no_index entries. .PP .Vb 1 \& my @filtered_provides = $self\->_apply_meta_noindex( @provides ) .Ve .PP is the suggested use. .PP Returns either an empty list, or a list of \f(CW\*(C`ProvideRecord\*(C'\fR's .SH "SEE ALSO" .IX Header "SEE ALSO" .IP "\(bu" 4 Dist::Zilla::Role::MetaProvider .IP "\(bu" 4 Dist::Zilla::Plugin::MetaProvider .IP "\(bu" 4 Dist::Zilla::MetaProvides::ProvideRecord .SH "THANKS" .IX Header "THANKS" .IP "\(bu" 4 Thanks to David Golden ( xdg / \s-1DAGOLDEN \s0) for the suggestion of the no_index feature for compatibility with MetaNoIndex plugin. .SH "AUTHOR" .IX Header "AUTHOR" Kent Fredric .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" This software is copyright (c) 2016 by Kent Fredric . .PP This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.