MooseX::Types::Common::String - Commonly used string types
use MooseX::Types::Common::String qw/SimpleStr/; has short_str => (is => 'rw', isa => SimpleStr); ... #this will fail $object->short_str("string\nwith\nbreaks");
A set of commonly-used string type constraints that do not ship with Moose by default.
SimpleStr
A Str with no new-line characters.
NonEmptySimpleStr
Does what it says on the tin.
Password
StrongPassword
NonEmptyStr
MooseX::Types::Common::Numeric
Please see:: MooseX::Types::Common
To install MooseX::Types::Common, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MooseX::Types::Common
CPAN shell
perl -MCPAN -e shell install MooseX::Types::Common
For more information on module installation, please visit the detailed CPAN module installation guide.