1MooseX::Types::Common(3U)ser Contributed Perl DocumentatiMoonoseX::Types::Common(3)
2
3
4
6 MooseX::Types::Common - A library of commonly used type constraints
7
9 use MooseX::Types::Common::String qw/SimpleStr/;
10 has short_str => (is => 'rw', isa => SimpleStr);
11
12 ...
13 #this will fail
14 $object->short_str("string\nwith\nbreaks");
15
16
17
18 use MooseX::Types::Common::Numeric qw/PositiveInt/;
19 has count => (is => 'rw', isa => PositiveInt);
20
21 ...
22 #this will fail
23 $object->count(-33);
24
26 A set of commonly-used type constraints that do not ship with Moose by
27 default.
28
30 · MooseX::Types::Common::String
31
32 · MooseX::Types::Common::Numeric
33
34 · MooseX::Types
35
36 · Moose::Util::TypeConstraints
37
39 This distribution was extracted from the Reaction code base by
40 Guillermo Roditi (groditi).
41
42 The original authors of this library are:
43
44 · Matt S. Trout
45
46 · K. J. Cheetham
47
48 · Guillermo Roditi
49
51 This library is free software, you can redistribute it and/or modify it
52 under the same terms as Perl itself.
53
54
55
56perl v5.12.4 2011-08-31 MooseX::Types::Common(3)