Dpkg::Email::Address.3perl - Man Page

manage an email address

Description

It provides a class which is able to manage an email address, as used in deb822(5) data.

Functions

$regex = REGEX()

Returns the regex used to parse and validate an email address.

It matches two parts, the name and the email.

Methods

$addr = Dpkg::Email::Address->new($string)

Create a new object that can hold an email address.

$name = $addr->name([$name])

Get and optionally set the email address name.

Returns the current or new email name.

$email = $addr->email([$email])

Get and optionally set the email address email.

Returns the current or new email.

$bool = $addr->parse($string)

Parses $string into the current object replacing the current address.

Will die on parse errors.

$string = $addr->as_string()

Returns the email address formatted as a string.

$hashref = $addr->as_struct()

Returns the email address in a hashref with name and email keys.

Changes

Version 0.xx

This is a private module.

Info

2026-01-23 1.23.5 libdpkg-perl