We need to say new -> _new? what's the better way of doing this?
[gitmo/Moose.git] / lib / Moose / Meta / Role / Method / Required.pm
CommitLineData
faa0f968 1
2package Moose::Meta::Role::Method::Required;
3
4use strict;
5use warnings;
2cf88ade 6use metaclass;
7
8use overload '""' => sub { shift->name }, # stringify to method name
9 fallback => 1;
10
11use base qw(Class::MOP::Object);
faa0f968 12
dbe21639 13our $VERSION = '0.79';
75b95414 14$VERSION = eval $VERSION;
faa0f968 15our $AUTHORITY = 'cpan:STEVAN';
16
2cf88ade 17# This is not a Moose::Meta::Role::Method because it has no implementation, it
18# is just a name
19
20__PACKAGE__->meta->add_attribute('name' => (reader => 'name'));
d67145ed 21
bc336e8e 22sub new { shift->_new(@_) }
23
faa0f968 241;
25
26__END__
27
28=pod
29
30=head1 NAME
31
32Moose::Meta::Role::Method::Required - A Moose metaclass for required methods in Roles
33
34=head1 DESCRIPTION
35
36=head1 BUGS
37
d03bd989 38All complex software has bugs lurking in it, and this module is no
faa0f968 39exception. If you find a bug please either email me, or add the bug
40to cpan-RT.
41
42=head1 AUTHOR
43
44Stevan Little E<lt>stevan@iinteractive.comE<gt>
45
46=head1 COPYRIGHT AND LICENSE
47
2840a3b2 48Copyright 2006-2009 by Infinity Interactive, Inc.
faa0f968 49
50L<http://www.iinteractive.com>
51
52This library is free software; you can redistribute it and/or modify
53it under the same terms as Perl itself.
54
07b0f1a5 55=cut