NAME

Dist::Zilla::Role::MetaProvider::Provider - A Role for Metadata providers specific to the 'provider' key.

VERSION

version 1.10034117

PERFORMS ROLES

Dist::Zilla::Role::MetaProvider

REQUIRED METHODS FOR PERFORMING ROLES

provides

Must return an array full of Dist::Zilla::MetaProvider::ProvideRecord instances.

ATTRIBUTES / PARAMETERS

inherit_version

This dictates how to report versions.

values

  • Set to "1" [default] The version defined by Dist::Zilla is the authority, and all versions discovered in packages are ignored.

  • Set to "0" The version defined in the discovered class is the authority, and it is copied to the provides metadata.

( To use this feature in a performing class, see "_resolve_version" )

inherit_missing

This dictates how to react when a class is discovered but a version is not specified.

values

  • Set to "1" [default] dist.ini's version turns up in the final metadata.

  • Set to "0". A provide turns up in the final metadata without a version, which is permissible.

( To use this feature in a performing class, see "_resolve_version" )

PRIVATE METHODS

_resolve_version

This is a utility method to make performing classes life easier in adhering to user requirements.

my $params  = {
    file => $somefile ,
    $self->_resolve_version( $version );
}

is the suggested use.

Returns either an empty list, or a list with ('version', $version );

This is so { version => undef } does not occur in the YAML.

PUBLIC METHODS

metadata

Fullfills the requirement of Dist::Zilla::Role::MetaProvider by processing results returned from $self->provides.

SEE ALSO

AUTHOR

Kent Fredric <kentnl@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2010 by Kent Fredric.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.