The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

Name

Class::Usul::TraitFor::MetaData - Class for CPAN Meta file

Synopsis

   use Moo;

   with 'Class::Usul::TraitFor::MetaData';

   $meta_data_object_ref = $self->get_package_meta( $directory );

Description

Loads the specified JSON file and returns on object which define accessors for it's attributes

Configuration and Environment

Defines the following attributes

abstract
author
license
name
provides
version

Subroutines/Methods

BUILDARGS

Monkey with the constructors signature

get_package_meta

   $response_obj = $self->get_package_meta( $dir );

Extracts; name, version, author and abstract from the META.json file. Looks in the optional $dir directory for the file in addition to $config->appldir and $config->ctrldir. Returns a response object with read-only accessors defined

Diagnostics

None

Dependencies

Moo

Incompatibilities

There are no known incompatibilities in this module

Bugs and Limitations

There are no known bugs in this module. Please report problems to the address below. Patches are welcome

Author

Peter Flanigan, <pjfl@cpan.org>

License and Copyright

Copyright (c) 2014 Peter Flanigan. All rights reserved

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See perlartistic

This program is distributed in the hope that it will be useful, but WITHOUT WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE