NAME
Devel::Ladybug::EmailAddr - Overloaded RFC 2822 email address object
SYNOPSIS
use Devel::Ladybug::EmailAddr;
#
# From address:
#
do {
my $addr = Devel::Ladybug::EmailAddr->new('root@example.com');
}
#
# From name and address:
#
do {
my $addr = Devel::Ladybug::EmailAddr->new("Rewt", 'root@example.com');
}
#
# From a formatted string:
#
do {
my $addr = Devel::Ladybug::EmailAddr->new("Rewt <root@example.com>');
}
DESCRIPTION
Extends Email::Address, Devel::Ladybug::Array. Uses Data::Validate::Email to verify input.
PUBLIC CLASS METHODS
assert(Devel::Ladybug::Class $class: *@rules)
Returns a new Devel::Ladybug::Type::EmailAddr instance which encapsulates the received Devel::Ladybug::Subtype rules.
create "YourApp::Example::" => { someAddr => Devel::Ladybug::EmailAddr->assert( subtype( optional => true ) ), # ... };
new(Devel::Ladybug::Class $class: Str $addr)
Returns a new Devel::Ladybug::EmailAddr instance which encapsulates the received value.
my $object = Devel::Ladybug::EmailAddr->new('root@example.com');
SEE ALSO
See Email::Address for RFC-related methods inherited by this class.
Devel::Ladybug::Array, Data::Validate::Email
This file is part of Devel::Ladybug::Net.