| 1 | package Reaction::Types::Email; | ||
| 2 | |||
| 3 | use MooseX::Types | ||
| 4 | 1 | ▶ | -declare => [qw/EmailAddress/]; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 1 | ▶ | use Reaction::Types::Core 'NonEmptySimpleStr'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | 1 | ▶ | use Email::Valid; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | |||
| 9 | subtype EmailAddress, | ||
| 10 | as NonEmptySimpleStr, | ||
| 11 | 0 | ▶ | where { Email::Valid->address($_) }, |
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||
| 12 | 0 | ▶ | message { "Must be a valid e-mail address" }; |
|
Subroutine
__ANON__: not called CC=1 SCAR=1.2
| |||
| 13 | |||
| 14 | 1 | 1; | |
| 15 | |||
| 16 | =head1 NAME | ||
| 17 | |||
| 18 | Reaction::Types::Email | ||
| 19 | |||
| 20 | =head1 DESCRIPTION | ||
| 21 | |||
| 22 | =over | ||
| 23 | |||
| 24 | =item * EmailAddress | ||
| 25 | |||
| 26 | =back | ||
| 27 | |||
| 28 | =head1 SEE ALSO | ||
| 29 | |||
| 30 | =over | ||
| 31 | |||
| 32 | =item * L<Reaction::Types::Core> | ||
| 33 | |||
| 34 | =back | ||
| 35 | |||
| 36 | =head1 AUTHORS | ||
| 37 | |||
| 38 | See L<Reaction::Class> for authors. | ||
| 39 | |||
| 40 | =head1 LICENSE | ||
| 41 | |||
| 42 | See L<Reaction::Class> for the license. | ||
| 43 | |||
| 44 | =cut | ||