Add built local::lib
[catagits/Gitalist.git] / local-lib5 / lib / perl5 / MooseX / MethodAttributes / Role / AttrContainer.pm
1 package MooseX::MethodAttributes::Role::AttrContainer;
2 our $VERSION = '0.18';
3
4 # ABSTRACT: capture code attributes in the class' metaclass
5
6 use Moose::Role;
7 use Moose::Util qw/find_meta/;
8
9 use namespace::clean -except => 'meta';
10
11
12 sub MODIFY_CODE_ATTRIBUTES {
13     my ($class, $code, @attrs) = @_;
14     find_meta($class)->register_method_attributes($code, \@attrs);
15     return ();
16 }
17
18 1;
19
20 __END__
21
22 =pod
23
24 =head1 NAME
25
26 MooseX::MethodAttributes::Role::AttrContainer - capture code attributes in the class' metaclass
27
28 =head1 VERSION
29
30 version 0.18
31
32 =head1 METHODS
33
34 =head2 MODIFY_CODE_ATTRIBUTES ($code, @attrs)
35
36 Accepts a list of attributes for a coderef and stores it the class' metaclass.
37
38 See L<attributes>.
39
40
41
42 =head1 AUTHORS
43
44   Florian Ragwitz <rafl@debian.org>
45   Tomas Doran <bobtfish@bobtfish.net>
46
47 =head1 COPYRIGHT AND LICENSE
48
49 This software is copyright (c) 2009 by Florian Ragwitz.
50
51 This is free software; you can redistribute it and/or modify it under
52 the same terms as perl itself.
53
54 =cut 
55
56