File Coverage

blib/lib/MooseX/MethodAttributes/Role/AttrContainer/Inheritable.pm
Criterion Covered Total %
statement 9 9 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 12 12 100.0


line stmt bran cond sub pod time code
1             package MooseX::MethodAttributes::Role::AttrContainer::Inheritable;
2             # ABSTRACT: capture code attributes in the automatically initialized metaclass instance
3              
4             our $VERSION = '0.32';
5              
6             #pod =head1 DESCRIPTION
7             #pod
8             #pod This role extends C<MooseX::MethodAttributes::Role::AttrContainer> with the
9             #pod functionality of automatically initializing a metaclass for the caller and
10             #pod applying the meta roles relevant for capturing method attributes.
11             #pod
12             #pod =cut
13              
14 10     10   1996907 use Moose::Role;
  10         76  
  10         89  
15 10     10   55715 use MooseX::MethodAttributes ();
  10         34  
  10         243  
16              
17 10     10   56 use namespace::autoclean;
  10         23  
  10         77  
18              
19             with 'MooseX::MethodAttributes::Role::AttrContainer';
20              
21             before MODIFY_CODE_ATTRIBUTES => sub {
22             my ($class, $code, @attrs) = @_;
23             return unless @attrs;
24             MooseX::MethodAttributes->init_meta( for_class => $class );
25             };
26              
27             1;
28              
29             __END__
30              
31             =pod
32              
33             =encoding UTF-8
34              
35             =head1 NAME
36              
37             MooseX::MethodAttributes::Role::AttrContainer::Inheritable - capture code attributes in the automatically initialized metaclass instance
38              
39             =head1 VERSION
40              
41             version 0.32
42              
43             =head1 DESCRIPTION
44              
45             This role extends C<MooseX::MethodAttributes::Role::AttrContainer> with the
46             functionality of automatically initializing a metaclass for the caller and
47             applying the meta roles relevant for capturing method attributes.
48              
49             =head1 SUPPORT
50              
51             Bugs may be submitted through L<the RT bug tracker|https://rt.cpan.org/Public/Dist/Display.html?Name=MooseX-MethodAttributes>
52             (or L<bug-MooseX-MethodAttributes@rt.cpan.org|mailto:bug-MooseX-MethodAttributes@rt.cpan.org>).
53              
54             There is also a mailing list available for users of this distribution, at
55             L<http://lists.perl.org/list/moose.html>.
56              
57             There is also an irc channel available for users of this distribution, at
58             L<C<#moose> on C<irc.perl.org>|irc://irc.perl.org/#moose>.
59              
60             =head1 AUTHORS
61              
62             =over 4
63              
64             =item *
65              
66             Florian Ragwitz <rafl@debian.org>
67              
68             =item *
69              
70             Tomas Doran <bobtfish@bobtfish.net>
71              
72             =back
73              
74             =head1 COPYRIGHT AND LICENCE
75              
76             This software is copyright (c) 2009 by Florian Ragwitz.
77              
78             This is free software; you can redistribute it and/or modify it under
79             the same terms as the Perl 5 programming language system itself.
80              
81             =cut