Tomas Doran > MooseX-Types-Email-0.004 > MooseX::Types::Email

Download:
MooseX-Types-Email-0.004.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Module Version: 0.004   Source   Latest Release: MooseX-Types-Email-0.006

NAME ^

MooseX::Types::Email - Email address validation type constraint for Moose.

SYNOPSIS ^

    package MyClass;
    use Moose;
    use MooseX::Types::Email qw/EmailAddress EmailMessage/;
    use namespace::autoclean;

    has email => ( isa => EmailAddress, required => 1, is => 'ro' );
    has message => ( isa => EmailMessage, required => 1, is => 'ro' );

DESCRIPTION ^

Moose type constraints which uses Email::Valid and Email::Abstract to check for valid email addresses and messages.

Note that EmailMessage must be an object that can be passed to Email::Abstract. Currently, constraining strings is not supported due to the leniency of Email::Abstract.

SEE ALSO ^

Moose::Util::TypeConstraints
MooseX::Types
Email::Valid
Email::Abstract

AUTHORS ^

Tomas Doran (t0m) <bobtfish@bobtfish.net>

Shamelessly extracted from Reaction::Types::Email.

CONTRIBUTORS ^

Chris Nehren <apeiron@cpan.org> added support for validing email messages.

COPYRIGHT ^

Copyright 2009 the above AUTHORS and CONTRIBUTORS.

LICENSE ^

This library is free software, you can redistribute it and/or modify it under the same terms as Perl itself.

syntax highlighting: