1Email::MessageID(3)   User Contributed Perl Documentation  Email::MessageID(3)
2
3
4

NAME

6       Email::MessageID - Generate world unique message-ids.
7

SYNOPSIS

9         use Email::MessageID;
10
11         my $mid = Email::MessageID->new;
12
13         print "Message-ID: $mid\x0A\x0D";
14

DESCRIPTION

16       Message-ids are optional, but highly recommended, headers that identify
17       a message uniquely. This software generates a unique message-id.
18

METHODS

20   new
21         my $mid = Email::MessageID->new;
22
23         my $new_mid = Email::MessageID->new( host => $myhost );
24
25       This class method constructs an Email::Address object containing a
26       unique message-id. You may specify custom "host" and "user" parameters.
27
28       By default, the "host" is generated from "Sys::Hostname::hostname".
29
30       By default, the "user" is generated using "Time::HiRes"'s
31       "gettimeofday" and the process ID.
32
33       Using these values we have the ability to ensure world uniqueness down
34       to a specific process running on a specific host, and the exact time
35       down to six digits of microsecond precision.
36
37   create_host
38         my $domain_part = Email::MessageID->create_host;
39
40       This method returns the domain part of the message-id.
41
42   create_user
43         my $local_part = Email::MessageID->create_user;
44
45       This method returns a unique local part for the message-id.  It
46       includes some random data and some predictable data.
47
48   in_brackets
49       The Message-Id header must start and end with angle brackets.  This is
50       a common mistake:
51
52         header => [
53           ...
54           'Message-Id' => Email::MessageID->new->as_string,
55         ],
56
57       Instead, use "in_brackets" to get the string inside angle brackets.
58

SEE ALSO

60       Email::Address, Time::HiRes, Sys::Hostname, perl.
61

PERL EMAIL PROJECT

63       This module is maintained by the Perl Email Project.
64
65       <http://emailproject.perl.org/wiki/Email::MessageID>
66

AUTHOR

68       Casey West, <casey@geeknest.com>.
69
71         Copyright (c) 2004 Casey West.  All rights reserved.
72         This module is free software; you can redistribute it and/or modify it
73         under the same terms as Perl itself.
74
75
76
77perl v5.12.0                      2009-01-24               Email::MessageID(3)
Impressum