Commit | Line | Data |
3379cc45 |
1 | package MooseX::Types::Common; |
2 | |
3 | use strict; |
4 | use warnings; |
5 | |
6 | our $VERSION = '0.001000'; |
7 | |
3379cc45 |
8 | 1; |
9 | |
10 | =head1 NAME |
11 | |
12 | MooseX::Types::Common |
13 | |
14 | =head1 SYNOPSIS |
15 | |
ac73ab52 |
16 | use MooseX::Types::Common::String qw/SimpleStr/; |
3379cc45 |
17 | has short_str => (is => 'rw', isa => SimpleStr); |
18 | |
19 | ... |
20 | #this will fail |
21 | $object->short_str("string\nwith\nbreaks"); |
22 | |
3379cc45 |
23 | |
3379cc45 |
24 | |
ac73ab52 |
25 | use MooseX::Types::Common::Numeric qw/PositiveInt/; |
26 | has count => (is => 'rw', isa => PositiveInt); |
3379cc45 |
27 | |
ac73ab52 |
28 | ... |
29 | #this will fail |
30 | $object->count(-33); |
3379cc45 |
31 | |
ac73ab52 |
32 | =head1 DESCRIPTION |
3379cc45 |
33 | |
ac73ab52 |
34 | A set of commonly-used type constraints that do not ship with Moose by default. |
3379cc45 |
35 | |
36 | =head1 SEE ALSO |
37 | |
38 | =over |
39 | |
ac73ab52 |
40 | =item * L<MooseX::Types::Common::String> |
41 | |
42 | =item * L<MooseX::Types::Common::Numeric> |
43 | |
3379cc45 |
44 | =item * L<MooseX::Types> |
45 | |
46 | =item * L<Moose::Util::TypeConstraints> |
47 | |
48 | =back |
49 | |
50 | =head1 AUTHORS |
51 | |
52 | This distribution was extracted from the L<Reaction> code base by Guillermo |
53 | Roditi (groditi). |
54 | |
55 | The original authors of this library are: |
56 | |
57 | =over 4 |
58 | |
59 | =item * Matt S. Trout |
60 | |
61 | =item * K. J. Cheetham |
62 | |
63 | =item * Guillermo Roditi |
64 | |
65 | =back |
66 | |
67 | =head1 LICENSE |
68 | |
69 | This library is free software, you can redistribute it and/or modify |
70 | it under the same terms as Perl itself. |
71 | |
72 | =cut |