line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package MooseX::MethodAttributes::Role::Meta::Method::MaybeWrapped; |
2
|
|
|
|
|
|
|
# ABSTRACT: proxy attributes of wrapped methods if their metaclass supports it |
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
our $VERSION = '0.30'; |
5
|
|
|
|
|
|
|
|
6
|
20
|
|
|
20
|
|
125359
|
use Moose::Role; |
|
20
|
|
|
|
|
54
|
|
|
20
|
|
|
|
|
214
|
|
7
|
20
|
|
|
20
|
|
105352
|
use Moose::Util qw/does_role/; |
|
20
|
|
|
|
|
48
|
|
|
20
|
|
|
|
|
168
|
|
8
|
20
|
|
|
20
|
|
17456
|
use MooseX::MethodAttributes::Role::Meta::Method::Wrapped; |
|
20
|
|
|
|
|
55
|
|
|
20
|
|
|
|
|
638
|
|
9
|
|
|
|
|
|
|
|
10
|
20
|
|
|
20
|
|
121
|
use namespace::autoclean; |
|
20
|
|
|
|
|
38
|
|
|
20
|
|
|
|
|
88
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
override wrap => sub { |
13
|
|
|
|
|
|
|
my $self = super; |
14
|
|
|
|
|
|
|
my $original_method = $self->get_original_method; |
15
|
|
|
|
|
|
|
if ( |
16
|
|
|
|
|
|
|
does_role($original_method, 'MooseX::MethodAttributes::Role::Meta::Method') |
17
|
|
|
|
|
|
|
|| does_role($original_method, 'MooseX::MethodAttributes::Role::Meta::Method::Wrapped') |
18
|
|
|
|
|
|
|
) { |
19
|
|
|
|
|
|
|
MooseX::MethodAttributes::Role::Meta::Method::Wrapped->meta->apply($self); |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
return $self; |
22
|
|
|
|
|
|
|
}; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__END__ |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=pod |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=encoding UTF-8 |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 NAME |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
MooseX::MethodAttributes::Role::Meta::Method::MaybeWrapped - proxy attributes of wrapped methods if their metaclass supports it |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=head1 VERSION |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
version 0.30 |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=head1 AUTHORS |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=over 4 |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=item * |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
Florian Ragwitz <rafl@debian.org> |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=item * |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
Tomas Doran <bobtfish@bobtfish.net> |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=back |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
This software is copyright (c) 2009 by Florian Ragwitz. |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
59
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=cut |