Commit | Line | Data |
a01f08fb |
1 | |
0f8232b6 |
2 | package MooseX::Getopt::Meta::Attribute::NoGetopt; |
a01f08fb |
3 | use Moose; |
a01f08fb |
4 | |
5 | our $VERSION = '0.01'; |
6 | our $AUTHORITY = 'cpan:STEVAN'; |
7 | |
8 | extends 'Moose::Meta::Attribute'; # << Moose extending Moose :) |
9 | |
10 | no Moose; |
11 | |
12 | # register this as a metaclass alias ... |
6ac028c4 |
13 | package # stop confusing PAUSE |
14 | Moose::Meta::Attribute::Custom::NoGetopt; |
0f8232b6 |
15 | sub register_implementation { 'MooseX::Getopt::Meta::Attribute::NoGetopt' } |
a01f08fb |
16 | |
f969917f |
17 | 1; |
18 | |
19 | __END__ |
20 | |
21 | =pod |
22 | |
23 | =head1 NAME |
24 | |
6ac028c4 |
25 | MooseX::Getopt::Meta::Attribute::NoGetopt - Optional meta attribute for ignoring params |
f969917f |
26 | |
27 | =head1 SYNOPSIS |
28 | |
29 | package App; |
30 | use Moose; |
31 | |
32 | with 'MooseX::Getopt'; |
33 | |
34 | has 'data' => ( |
6ac028c4 |
35 | metaclass => 'NoGetopt', # do not attempt to capture this param |
f969917f |
36 | is => 'ro', |
37 | isa => 'Str', |
38 | default => 'file.dat', |
39 | ); |
40 | |
41 | =head1 DESCRIPTION |
42 | |
43 | This is a custom attribute metaclass which can be used to specify |
44 | that a specific attribute should B<not> be processed by |
6ac028c4 |
45 | C<MooseX::Getopt>. All you need to do is specify the C<NoGetopt> |
f969917f |
46 | metaclass. |
47 | |
48 | has 'foo' => (metaclass => 'NoGetopt', ... ); |
49 | |
50 | =head1 METHODS |
51 | |
52 | =over 4 |
53 | |
54 | =item B<meta> |
55 | |
56 | =back |
57 | |
58 | =head1 BUGS |
59 | |
60 | All complex software has bugs lurking in it, and this module is no |
61 | exception. If you find a bug please either email me, or add the bug |
62 | to cpan-RT. |
63 | |
64 | =head1 AUTHOR |
65 | |
66 | Stevan Little E<lt>stevan@iinteractive.comE<gt> |
67 | |
68 | Chris Prather C<< <perigrin@cpan.org> >> |
69 | |
70 | =head1 COPYRIGHT AND LICENSE |
71 | |
72 | Copyright 2007 by Infinity Interactive, Inc. |
73 | |
74 | L<http://www.iinteractive.com> |
75 | |
76 | This library is free software; you can redistribute it and/or modify |
77 | it under the same terms as Perl itself. |
78 | |
79 | =cut |