/usr/share/perl5/Mail/Message/Head/Complete.pod is in libmail-message-perl 3.006-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 | =encoding utf8
=head1 NAME
Mail::Message::Head::Complete - the header of one message
=head1 INHERITANCE
Mail::Message::Head::Complete
is a Mail::Message::Head
is a Mail::Reporter
Mail::Message::Head::Complete is extended by
Mail::Message::Head::Partial
Mail::Message::Replace::MailHeader
Mail::Message::Head::Complete is realized by
Mail::Message::Head::Delayed
Mail::Message::Head::Subset
=head1 SYNOPSIS
my $head = Mail::Message::Head::Complete->new;
See Mail::Message::Head
=head1 DESCRIPTION
E-mail's message can be in various states: unread, partially read, and
fully read. The class stores a message of which all header lines are
known for sure.
Extends L<"DESCRIPTION" in Mail::Message::Head|Mail::Message::Head/"DESCRIPTION">.
=head1 OVERLOADED
Extends L<"OVERLOADED" in Mail::Message::Head|Mail::Message::Head/"OVERLOADED">.
=over 4
=item overload: B<"">
Inherited, see L<Mail::Message::Head/"OVERLOADED">
=item overload: B<bool>
Inherited, see L<Mail::Message::Head/"OVERLOADED">
=back
=head1 METHODS
Extends L<"METHODS" in Mail::Message::Head|Mail::Message::Head/"METHODS">.
=head2 Constructors
Extends L<"Constructors" in Mail::Message::Head|Mail::Message::Head/"Constructors">.
=over 4
=item Mail::Message::Head::Complete-E<gt>B<build>( [PAIR|$field], ... )
Undefined values are interpreted as empty field values, and therefore skipped.
=item $obj-E<gt>B<clone>( [@names|ARRAY|Regexps] )
Make a copy of the header, optionally limited only to the header lines
specified by @names. See L<grepNames()|Mail::Message::Head::Complete/"Access to the header"> on the way these fields can be
used.
example:
my $newhead = $head->clone('Subject', 'Received');
=item Mail::Message::Head::Complete-E<gt>B<new>(%options)
Inherited, see L<Mail::Message::Head/"Constructors">
=back
=head2 The header
Extends L<"The header" in Mail::Message::Head|Mail::Message::Head/"The header">.
=over 4
=item $obj-E<gt>B<isDelayed>()
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<isEmpty>()
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<isModified>()
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<knownNames>()
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<message>( [$message] )
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<modified>( [BOOLEAN] )
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<nrLines>()
Return the number of lines needed to display this header (including
the trailing newline)
=item $obj-E<gt>B<orderedFields>()
Inherited, see L<Mail::Message::Head/"The header">
=item $obj-E<gt>B<size>()
Return the number of bytes needed to display this header (including
the trailing newline). On systems which use CRLF as line separator,
the number of lines in the header (see L<nrLines()|Mail::Message::Head::Complete/"The header">) must be added to
find the actual size in the file.
=item $obj-E<gt>B<wrap>($integer)
Re-fold all fields from the header to contain at most $integer number of
characters per line.
example: re-folding a header
$msg->head->wrap(78);
=back
=head2 Access to the header
Extends L<"Access to the header" in Mail::Message::Head|Mail::Message::Head/"Access to the header">.
=over 4
=item $obj-E<gt>B<add>( $field | $line | <$name, $body, [$attrs]> )
Add a field to the header. If a field is added more than once, all values
are stored in the header, in the order they are added.
When a $field object is specified (some L<Mail::Message::Field|Mail::Message::Field> instance), that
will be added. Another possibility is to specify a raw header $line, or a
header line nicely split-up in $name and $body, in which case the
field constructor is called for you.
$line or $body specifications which are terminated by a new-line are considered
to be correctly folded. Lines which are not terminated by a new-line will
be folded when needed: new-lines will be added where required. It is strongly
advised to let MailBox do the folding for you.
The return value of this method is the L<Mail::Message::Field|Mail::Message::Field> object
which is created (or was specified).
example:
my $head = Mail::Message::Head->new;
$head->add('Subject: hi!');
$head->add(From => 'me@home');
my $field = Mail::Message::Field->new('To: you@there');
$head->add($field);
my Mail::Message::Field $s = $head->add(Sender => 'I');
=item $obj-E<gt>B<addListGroup>($object)
A I<list group> is a set of header fields which contain data about a
mailing list which was used to transmit the message. See
L<Mail::Message::Head::ListGroup|Mail::Message::Head::ListGroup> for details about the implementation
of the $object.
When you have a list group prepared, you can add it later using this
method. You will get your private copy of the list group data in
return, because the same group can be used for multiple messages.
example: of adding a list group to a header
my $lg = Mail::Message::Head::ListGroup->new(...);
my $own_lg = $msg->head->addListGroup($lg);
=item $obj-E<gt>B<addResentGroup>($resent_group|$data)
Add a $resent_group (a L<Mail::Message::Head::ResentGroup|Mail::Message::Head::ResentGroup> object) to
the header. If you specify $data, that is used to create such group
first. If no C<Received> line is specified, it will be created
for you.
These header lines have nothing to do with the user's sense
of C<reply> or C<forward> actions: these lines trace the e-mail
transport mechanism.
example:
my $rg = Mail::Message::Head::ResentGroup->new(head => $head, ...);
$head->addResentGroup($rg);
my $rg = $head->addResentGroup(From => 'me');
=item $obj-E<gt>B<addSpamGroup>($object)
A I<spam fighting group> is a set of header fields which contains data
which is used to fight spam. See L<Mail::Message::Head::SpamGroup|Mail::Message::Head::SpamGroup>
for details about the implementation of the $object.
When you have a spam group prepared, you can add it later using this
method. You will get your private copy of the spam group data in
return, because the same group can be used for multiple messages.
example: of adding a spam group to a header
my $sg = Mail::Message::Head::SpamGroup->new(...);
my $own_sg = $msg->head->addSpamGroup($sg);
=item $obj-E<gt>B<count>($name)
Count the number of fields with this $name. Most fields will return 1:
only one occurrence in the header. As example, the C<Received> fields
are usually present more than once.
=item $obj-E<gt>B<delete>($name)
Remove the field with the specified name. If the header contained
multiple lines with the same name, they will be replaced all together.
This method simply calls L<reset()|Mail::Message::Head::Complete/"Access to the header"> without replacement fields.
READ THE IMPORTANT WARNING IN L<removeField()|Mail::Message::Head::Complete/"Access to the header">
=item $obj-E<gt>B<get>( $name, [$index] )
Inherited, see L<Mail::Message::Head/"Access to the header">
=item $obj-E<gt>B<grepNames>( [@names|ARRAY|Regexps] )
Filter from all header fields those with names which start will any of the
specified list. When no names are specified, all fields will be returned.
The list is ordered as they where read from file, or added later.
The @names are considered regular expressions, and will all be matched
case insensitive and attached to the front of the string only. You may
also specify one or more prepared regexes.
example:
my @f = $head->grepNames(); # same as $head->orderedFields
my @f = $head->grepNames('X-', 'Subject', ');
my @to = $head->grepNames('To\b'); # will only select To
=item $obj-E<gt>B<listGroup>()
Returns a I<list group> description: the set of headers which form
the information about mailing list software used to transport the
message. See also L<addListGroup()|Mail::Message::Head::Complete/"Access to the header"> and L<removeListGroup()|Mail::Message::Head::Complete/"Access to the header">.
example: use of listGroup()
if(my $lg = $msg->head->listGroup)
{ $lg->print(\*STDERR);
$lg->delete;
}
$msg->head->removeListGroup;
=item $obj-E<gt>B<names>()
Returns a full ordered list of known field names, as defined in the
header. Fields which were reset() to be empty will still be
listed here.
=item $obj-E<gt>B<print>( [$fh] )
Print all headers to the specified $fh, by default the selected
filehandle. See L<printUndisclosed()|Mail::Message::Head::Complete/"Access to the header"> to limit the headers to include
only the public headers.
example:
$head->print(\*OUT);
$head->print;
my $fh = IO::File->new(...);
$head->print($fh);
=item $obj-E<gt>B<printSelected>($fh, <STRING|Regexp>, ...)
Like the usual L<print()|Mail::Message::Head::Complete/"Access to the header">, the header lines are printed to the specified
$fh. In this case, however, only the fields with names as specified by
STRING (case insensative) or Regexp are printed. They will stay the in-order
of the source header.
example: printing only a subset of the fields
$head->printSelected(STDOUT, qw/Subject From To/, qr/^x\-(spam|xyz)\-/i)
=item $obj-E<gt>B<printUndisclosed>( [$fh] )
Like the usual L<print()|Mail::Message::Head::Complete/"Access to the header">, the header lines are printed to the specified
$fh, by default the selected filehandle. In this case, however,
C<Bcc> and C<Resent-Bcc> lines are included.
=item $obj-E<gt>B<removeContentInfo>()
Remove all body related fields from the header. The header will become
partial.
=item $obj-E<gt>B<removeField>($field)
Remove the specified $field object from the header. This is useful when
there are possible more than one fields with the same name, and you
need to remove exactly one of them. Also have a look at L<delete()|Mail::Message::Head::Complete/"Access to the header">,
L<reset()|Mail::Message::Head::Complete/"Access to the header">, and L<set()|Mail::Message::Head::Complete/"Access to the header">.
See also L<Mail::Message::Head::Partial::removeFields()|Mail::Message::Head::Partial/"Access to the header"> (mind the 's'
at the end of the name), which accepts a string or regular expression
as argument to select the fields to be removed.
WARNING WARNING WARNING: for performance reasons, the header administration
uses weak references (see L<Scalar::Util> method weaken()> to figure-out
which fields have been removed. A header is a hash of field for fast search
and an array of weak references to remember the order of the fields, required
for printing. If the field is removed from the hash, the weak-ref is set to
undef and the field not printed.
However... it is easy to disturb this process. Example:
my $msg = ....; # subject ref-count = 1 + 0 = 1
$msg->head->delete('Subject'); # subject ref-count = 0 = 0: clean-up
$msg->print; # subject doesn't show: ok
But
my $msg = ....; # subject ref-count = 1 + 0 = 1
my $s = $msg->head->get('subject'); # ref-count = 1 + 1 + 0 = 2
$msg->head->delete('Subject'); # subject ref-count = 1 + 0 = 1: no clean-up
$msg->print; # subject DOES show: not ok
undef $s; # ref-count becomes 0: clean-up
$msg->print; # subject doesn't show: ok
To avoid the latter situation, do not catch the field object, but only
the field content. SAVE are all methods which return the text:
my $s = $msg->head->get('subject')->body;
my $s = $msg->head->get('subject')->unfoldedBody;
my $s = $msg->head->get('subject')->foldedBody;
my $s = $msg->head->get('subject')->foldedBody;
my $s = $msg->get('subject');
my $s = $msg->subject;
my $s = $msg->string;
=item $obj-E<gt>B<removeFields>( <STRING|Regexp>, ... )
The header object is turned into a L<Mail::Message::Head::Partial|Mail::Message::Head::Partial> object
which has a set of fields removed. Read about the implications and the
possibilities in L<Mail::Message::Head::Partial::removeFields()|Mail::Message::Head::Partial/"Access to the header">.
=item $obj-E<gt>B<removeFieldsExcept>( <STRING|Regexp>, ... )
The header object is turned into a L<Mail::Message::Head::Partial|Mail::Message::Head::Partial> object
which has a set of fields removed. Read about the implications and the
possibilities in L<Mail::Message::Head::Partial::removeFieldsExcept()|Mail::Message::Head::Partial/"Access to the header">.
=item $obj-E<gt>B<removeListGroup>()
Removes all fields related to mailing list administration at once.
The header object is turned into a L<Mail::Message::Head::Partial|Mail::Message::Head::Partial>
object. Read about the implications and the possibilities in
L<Mail::Message::Head::Partial::removeListGroup()|Mail::Message::Head::Partial/"Access to the header">.
=item $obj-E<gt>B<removeResentGroups>()
Removes all resent groups at once. The header object is turned into
a L<Mail::Message::Head::Partial|Mail::Message::Head::Partial> object. Read about the implications and the
possibilities in L<Mail::Message::Head::Partial::removeResentGroups()|Mail::Message::Head::Partial/"Access to the header">.
=item $obj-E<gt>B<removeSpamGroups>()
Removes all fields which were added by various spam detection software
at once. The header object is turned into a L<Mail::Message::Head::Partial|Mail::Message::Head::Partial>
object. Read about the implications and the possibilities in
L<Mail::Message::Head::Partial::removeSpamGroups()|Mail::Message::Head::Partial/"Access to the header">.
=item $obj-E<gt>B<resentGroups>()
Returns a list of L<Mail::Message::Head::ResentGroup|Mail::Message::Head::ResentGroup> objects which
each represent one intermediate point in the message's transmission in
the order as they appear in the header: the most recent one first.
See also L<addResentGroup()|Mail::Message::Head::Complete/"Access to the header"> and L<removeResentGroups()|Mail::Message::Head::Complete/"Access to the header">.
A resent group contains a set of header fields whose names start
with C<Resent-*>. Before the first C<Resent> line is I<trace> information,
which is composed of an optional C<Return-Path> field and an required
C<Received> field.
=item $obj-E<gt>B<reset>($name, @fields)
Replace the values in the header fields named by $name with the values
specified in the list of @fields. A single name can correspond to multiple
repeated fields. READ THE IMPORTANT WARNING IN L<removeField()|Mail::Message::Head::Complete/"Access to the header">
Removing fields which are part of one of the predefined field groups is
not a smart idea. You can better remove these fields as group, all
together. For instance, the C<'Received'> lines are part of resent
groups, C<'X-Spam'> is past of a spam group, and C<List-Post> belongs
to a list group. You can delete a whole group with
L<Mail::Message::Head::FieldGroup::delete()|Mail::Message::Head::FieldGroup/"The header">, or with methods which
are provided by L<Mail::Message::Head::Partial|Mail::Message::Head::Partial>.
If FIELDS is empty, the corresponding $name fields will
be removed. The location of removed fields in the header order will be
remembered. Fields with the same name which are added later will appear at
the remembered position. This is equivalent to the L<delete()|Mail::Message::Head::Complete/"Access to the header"> method.
example:
# reduce number of 'Keywords' lines to last 5)
my @keywords = $head->get('Keywords');
$head->reset('Keywords', @keywords[-5..-1]) if @keywords > 5;
# Reduce the number of Received lines to only the last added one.
my @rgs = $head->resentGroups;
shift @rgs; # keep this one (later is added in front)
$_->delete foreach @rgs;
=item $obj-E<gt>B<set>( $field | $line | <$name, $body, [$attrs]> )
The C<set> method is similar to the L<add()|Mail::Message::Head::Complete/"Access to the header"> method, and takes the same
options. However, existing values for fields will be removed before a new
value is added. READ THE IMPORTANT WARNING IN L<removeField()|Mail::Message::Head::Complete/"Access to the header">
=item $obj-E<gt>B<spamDetected>()
Returns whether one of the spam groups defines a report about spam. If there
are not header fields in the message which relate to spam-detection
software, C<undef> is returned. The spamgroups which report spam are returned.
example:
$message->delete if $message->spamDetected;
call_spamassassin($message)
unless defined $message->spamDetected;
=item $obj-E<gt>B<spamGroups>( [$names] )
Returns a list of L<Mail::Message::Head::SpamGroup|Mail::Message::Head::SpamGroup> objects, each collecting
some lines which contain spam fighting information. When any $names are
given, then only these groups are returned.
See also L<addSpamGroup()|Mail::Message::Head::Complete/"Access to the header"> and L<removeSpamGroups()|Mail::Message::Head::Complete/"Access to the header">.
In scalar context, with exactly one NAME specified, that group will be
returned. With more $names or without $names, a list will be returned
(which defaults to the length of the list in scalar context).
example: use of listGroup()
my @sg = $msg->head->spamGroups;
$sg[0]->print(\*STDERR);
$sg[-1]->delete;
my $sg = $msg->head->spamGroups('SpamAssassin');
=item $obj-E<gt>B<string>()
Returns the whole header as one scalar (in scalar context) or list
of lines (list context). Triggers completion.
=item $obj-E<gt>B<study>( $name, [$index] )
Inherited, see L<Mail::Message::Head/"Access to the header">
=back
=head2 About the body
Extends L<"About the body" in Mail::Message::Head|Mail::Message::Head/"About the body">.
=over 4
=item $obj-E<gt>B<guessBodySize>()
Inherited, see L<Mail::Message::Head/"About the body">
=item $obj-E<gt>B<guessTimeStamp>()
Make a guess about when the message was origanally posted, based on the
information found in the header's C<Date> field.
For some kinds of folders, L<Mail::Message::guessTimestamp()|Mail::Message/"The header"> may produce
a better result, for instance by looking at the modification time of the
file in which the message is stored. Also some protocols, like POP can
supply that information.
=item $obj-E<gt>B<isMultipart>()
Inherited, see L<Mail::Message::Head/"About the body">
=item $obj-E<gt>B<recvstamp>()
Returns an indication about when the message was sent, but only using the
C<Date> field in the header as last resort: we do not trust the sender of
the message to specify the correct date. See L<timestamp()|Mail::Message::Head::Complete/"About the body"> when you do
trust the sender.
Many spam producers fake a date, which mess up the order of receiving
things. The timestamp which is produced is derived from the Received
headers, if they are present, and C<undef> otherwise.
The timestamp is encoded as C<time> is on your system (see perldoc -f
time), and as such usable for the C<gmtime> and C<localtime> methods.
example: of time-sorting folders with received messages
my $folder = $mgr->open('InBox');
my @messages = sort {$a->recvstamp <=> $b->recvstamp}
$folder->messages;
example: of time-sorting messages of mixed origin
my $folder = $mgr->open('MyFolder');
# Pre-calculate timestamps to be sorted (for speed)
my @stamps = map { [ ($_->timestamp || 0), $_ ] }
$folder->messages;
my @sorted
= map { $_->[1] } # get the message for the stamp
sort {$a->[0] <=> $b->[0]} # stamps are numerics
@stamps;
=item $obj-E<gt>B<timestamp>()
Returns an indication about when the message was sent, with as
little guessing as possible. In this case, the date as specified by the
sender is trusted. See L<recvstamp()|Mail::Message::Head::Complete/"About the body"> when you do not want to trust the
sender.
The timestamp is encoded as C<time> is
on your system (see perldoc -f time), and as such usable for the C<gmtime>
and C<localtime> methods.
=back
=head2 Internals
Extends L<"Internals" in Mail::Message::Head|Mail::Message::Head/"Internals">.
=over 4
=item $obj-E<gt>B<addNoRealize>($field)
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<addOrderedFields>($fields)
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<createFromLine>()
For some mail-folder types separate messages by a line starting with
'C<From >'. If a message is moved to such folder from a folder-type
which does not support these separators, this method is called to produce
one.
=item $obj-E<gt>B<createMessageId>()
Creates a message-id for this message. This method will be run when
a new message is created, or a message is discovered without the
message-id header field. Message-ids are required for detection of
message-threads. See L<messageIdPrefix()|Mail::Message::Head::Complete/"Internals">.
=item $obj-E<gt>B<fileLocation>()
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<load>()
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<messageIdPrefix>( [$prefix, [$hostname]|CODE] )
=item Mail::Message::Head::Complete-E<gt>B<messageIdPrefix>( [$prefix, [$hostname]|CODE] )
When options are provided, it sets a new way to create message-ids,
as used by L<createMessageId()|Mail::Message::Head::Complete/"Internals">. You have two choices: either by
providing a $prefix and optionally a $hostname, or a CODE reference.
The CODE reference will be called with the header as first argument.
You must ensure yourself that the returned value is RFC compliant.
The $prefix defaults to C<mailbox-$$>, the $hostname defaults to the
return of L<Net::Domains>'s function C<hostfqdn()>, or when not installed,
the L<Sys::Hostname>'s function C<hostname()>. Inbetween the
two, a nano-second time provided by L<Time::HiRes> is used. If that
module is not available, C<time> is called at the start of the program,
and incremented for each newly created id.
In any case, a subroutine will be created to be used. A reference
to that will be returned. When the method is called without arguments,
but no subroutine is defined yet, one will be created.
example: setting a message prefix
$head->messageIdPrefix('prefix');
Mail::Message::Head::Complete->messageIdPrefix('prefix');
my $code = $head->messageIdPrefix('mailbox', 'nohost');
sub new_msgid()
{ my $head = shift;
"myid-$$-${(rand 10000)}@example.com";
}
$many_msg->messageIdPrefix(\&new_msgid);
Mail::Message::Head::Complete->messageIdPrefix(&new_msgid);
=item $obj-E<gt>B<moveLocation>($distance)
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<read>($parser)
Inherited, see L<Mail::Message::Head/"Internals">
=item $obj-E<gt>B<setNoRealize>($field)
Inherited, see L<Mail::Message::Head/"Internals">
=back
=head2 Error handling
Extends L<"Error handling" in Mail::Message::Head|Mail::Message::Head/"Error handling">.
=over 4
=item $obj-E<gt>B<AUTOLOAD>()
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<addReport>($object)
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<defaultTrace>( [$level]|[$loglevel, $tracelevel]|[$level, $callback] )
=item Mail::Message::Head::Complete-E<gt>B<defaultTrace>( [$level]|[$loglevel, $tracelevel]|[$level, $callback] )
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<errors>()
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<log>( [$level, [$strings]] )
=item Mail::Message::Head::Complete-E<gt>B<log>( [$level, [$strings]] )
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<logPriority>($level)
=item Mail::Message::Head::Complete-E<gt>B<logPriority>($level)
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<logSettings>()
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<notImplemented>()
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<report>( [$level] )
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<reportAll>( [$level] )
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<trace>( [$level] )
Inherited, see L<Mail::Reporter/"Error handling">
=item $obj-E<gt>B<warnings>()
Inherited, see L<Mail::Reporter/"Error handling">
=back
=head2 Cleanup
Extends L<"Cleanup" in Mail::Message::Head|Mail::Message::Head/"Cleanup">.
=over 4
=item $obj-E<gt>B<DESTROY>()
Inherited, see L<Mail::Reporter/"Cleanup">
=back
=head1 DETAILS
Extends L<"DETAILS" in Mail::Message::Head|Mail::Message::Head/"DETAILS">.
=head1 DIAGNOSTICS
=over 4
=item Warning: Cannot remove field $name from header: not found.
You ask to remove a field which is not known in the header. Using
L<delete()|Mail::Message::Head::Complete/"Access to the header">, L<reset()|Mail::Message::Head::Complete/"Access to the header">, or L<set()|Mail::Message::Head::Complete/"Access to the header"> to do the job will not result
in warnings: those methods check the existence of the field first.
=item Warning: Field objects have an implied name ($name)
=item Error: Package $package does not implement $method.
Fatal error: the specific package (or one of its superclasses) does not
implement this method where it should. This message means that some other
related classes do implement this method however the class at hand does
not. Probably you should investigate this and probably inform the author
of the package.
=back
=head1 SEE ALSO
This module is part of Mail-Message distribution version 3.006,
built on January 24, 2018. Website: F<http://perl.overmeer.net/CPAN/>
=head1 LICENSE
Copyrights 2001-2018 by [Mark Overmeer]. For other contributors see ChangeLog.
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
See F<http://dev.perl.org/licenses/>
|