Mail::...essage(3pm)

πŸ’– Mail::Box::POP3::Message(3pm) β€” the whole vibe πŸ’–

okay so bestie, sit down, hydrate, and let's talk about Mail::Box::POP3::Message β€” yes that's the full name, yes it's a 3pm perl manual page, and yes we're doing this together 🫢


✨ NAME ✨

Mail::Box::POP3::Message β€” it's one single message chillin' on a POP3 server. that's it. that's the whole job. πŸ’…


🧬 INHERITANCE 🧬

this class got main character energy and a whole ancestry line, look at her:

Mail::Box::POP3::Message
  is a Mail::Box::Net::Message
  is a Mail::Box::Message
  is a Mail::Message
  is a Mail::Reporter

so like, everything those parents can do? she can do. she's literally descended from royalty. the lineage is giving old money πŸ‘‘


✨ SYNOPSIS ✨

here's how you actually get your hands on one, no cap:

my $folder = new Mail::Box::POP3 ...
my $message = $folder->message(10);

you make the folder, then you just... ask for message number 10. iconic. slay. πŸŽ€


🌸 DESCRIPTION 🌸

so a Mail::Box::POP3::Message is one message living on a POP3 server, and it's kept and cared for by a Mail::Box::POP3 folder. think of the folder as the group chat and the message as, like, one text in it. πŸ’Œ

each message is stored as a separate entity on the server β€” so it's not all mashed together, she's her own independent girlie. and it maybe also lives temporarily inside your program while you're using it (so like, she can be in two places at once, lowkey). πŸ¦‹

and that's not all β€” this page extends "DESCRIPTION" in Mail::Box::Net::Message, so if you wanna know more, the parent page has the rest of the lore. iykyk πŸ”₯


more parts incoming bestie, don't go anywhere πŸ’œ

✨ METHODS ✨

Extends "METHODS" in Mail::Box::Net::Message.


πŸŽ€ Constructors πŸŽ€

Extends "Constructors" in Mail::Box::Net::Message.

  • $obj->clone(%options) β€” inherited bestie, go read "Constructors" in Mail::Message for the full tea πŸ’–
  • $class->new(%options) β€” also inherited, see "Constructors" in Mail::Reporter

so new() takes a whole lil menu of options and here's the exact cheat sheet, no cap:

 -Option    --Defined in             --Default
  body        Mail::Message            undef
  body_type   Mail::Box::Message       Mail::Message::Body::Lines
  deleted     Mail::Message            false
  field_type  Mail::Message            undef
  folder      Mail::Box::Message       <required>
  head        Mail::Message            undef
  head_type   Mail::Message            Mail::Message::Head::Complete
  labels      Mail::Message            +{}
  messageId   Mail::Message            undef
  message_id  Mail::Message            undef
  modified    Mail::Message            false
  size        Mail::Box::Message       undef
  trusted     Mail::Message            false
  unique      Mail::Box::Net::Message  <unique string>

and now what each one actually wants from u:

  • body => $object
  • body_type => CODE|$class
  • deleted => BOOLEAN
  • field_type => $class
  • folder => $folder
  • head => $object
  • head_type => $class
  • labels => \@pairs|\%settings
  • messageId => $id
  • message_id => $id
  • modified => BOOLEAN
  • size => $bytes
  • trusted => BOOLEAN
  • unique => STRING
folder is required btw, it's not optional, it's giving main character energy. don't forget it πŸ™ˆ

πŸ¦‹ Attributes πŸ¦‹

Extends "Attributes" in Mail::Box::Net::Message.

  • $obj->bodyType() β€” inherited, see "Attributes" in Mail::Message
  • $obj->fieldType() β€” inherited, see "Attributes" in Mail::Message
  • $obj->folder( [$folder] ) β€” inherited, see "Attributes" in Mail::Box::Message
  • $obj->headType() β€” inherited, see "Attributes" in Mail::Message
  • $obj->messageId() β€” inherited, see "Attributes" in Mail::Message
  • $obj->seqnr( [$integer] ) β€” inherited, see "Attributes" in Mail::Box::Message
  • $obj->unique( [STRING|undef] ) β€” inherited, see "Attributes" in Mail::Box::Net::Message

🌸 Constructing a message 🌸

Extends "Constructing a message" in Mail::Box::Net::Message.

  • $obj->bounce( [<$rg_object|%options>] ) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Bounce
  • $class->build( [$message|$part|$body], @fields, %options ) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Build
  • $class->buildFromBody($body, [$head], $headers) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Build
  • $obj->forward(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardAttach(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardEncapsulate(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardInline(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardNo(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardPostlude() β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardPrelude() β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $obj->forwardSubject(STRING) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Forward
  • $class->read($fh|$text|\$text|\@lines, %options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Read
  • $obj->rebuild(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Rebuild
  • $obj->reply(%options) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Reply
  • $obj->replyPrelude( [STRING|$field|$address|\@addrs|\@fields] ) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Reply
  • $any->replySubject(STRING) β€” inherited, see "Constructing a message" in Mail::Message::Construct::Reply

πŸ’… The message πŸ’…

Extends "The message" in Mail::Box::Net::Message.

  • $obj->container() β€” inherited, see "The message" in Mail::Message
  • $obj->copyTo($folder, %options) β€” inherited, see "The message" in Mail::Box::Message
  • $obj->endsOnNewline() β€” inherited, see "The message" in Mail::Message
  • $obj->isDummy() β€” inherited, see "The message" in Mail::Message
  • $obj->isPart() β€” inherited, see "The message" in Mail::Message
  • $obj->moveTo($folder, %options) β€” inherited, see "The message" in Mail::Box::Message
  • $obj->partNumber() β€” inherited, see "The message" in Mail::Message
  • $obj->print( [$fh] ) β€” inherited, see "The message" in Mail::Message
  • $obj->send( [$mailer], %options ) β€” inherited, see "The message" in Mail::Message
  • $obj->size() β€” hands u the size of this message, periodt. if the message is still chilling on the remote server, POP gets asked for the size. but if the message is already loaded onto the local system, the size of the parsed message is what u get. and yeah these two sizes can genuinely differ, because of the difference in line-ending representation 😭. Improves base, see "The message" in Mail::Message
  • $obj->toplevel() β€” inherited, see "The message" in Mail::Message
  • $obj->write( [$fh] ) β€” inherited, see "The message" in Mail::Message

πŸŽ€ The header πŸŽ€

Extends "The header" in Mail::Box::Net::Message.

  • $obj->bcc() β€” inherited, see "The header" in Mail::Message
  • $obj->cc() β€” inherited, see "The header" in Mail::Message
  • $obj->date() β€” inherited, see "The header" in Mail::Message
  • $obj->destinations() β€” inherited, see "The header" in Mail::Message
  • $obj->from() β€” inherited, see "The header" in Mail::Message
  • $obj->get($fieldname) β€” inherited, see "The header" in Mail::Message
  • $obj->guessTimestamp() β€” inherited, see "The header" in Mail::Message
  • $obj->head( [$head] ) β€” inherited, see "The header" in Mail::Message
  • $obj->nrLines() β€” inherited, see "The header" in Mail::Message
  • $obj->sender() β€” inherited, see "The header" in Mail::Message
  • $obj->study($fieldname) β€” inherited, see "The header" in Mail::Message
  • $obj->subject() β€” inherited, see "The header" in Mail::Message
  • $obj->timestamp() β€” inherited, see "The header" in Mail::Message
  • $obj->to() β€” inherited, see "The header" in Mail::Message

🧚 The body 🧚

Extends "The body" in Mail::Box::Net::Message.

  • $obj->body( [$body] ) β€” inherited, see "The body" in Mail::Message
  • $obj->contentType() β€” inherited, see "The body" in Mail::Message
  • $obj->decoded(%options) β€” inherited, see "The body" in Mail::Message
  • $obj->encode(%options) β€” inherited, see "The body" in Mail::Message
  • $obj->isMultipart() β€” inherited, see "The body" in Mail::Message
  • $obj->isNested() β€” inherited, see "The body" in Mail::Message
  • $obj->parts( [<'ALL'|'ACTIVE'|'DELETED'|'RECURSE'|$filter>] ) β€” inherited, see "The body" in Mail::Message

πŸ“ Flags πŸ“

Extends "Flags" in Mail::Box::Net::Message.

  • $obj->delete() β€” inherited, see "Flags" in Mail::Message
  • $obj->deleted( [BOOLEAN] ) β€” inherited, see "Flags" in Mail::Message
  • $obj->isDeleted() β€” inherited, see "Flags" in Mail::Message
  • $obj->isModified() β€” inherited, see "Flags" in Mail::Message
  • $obj->label($label|PAIRS) β€” inherited, see "Flags" in Mail::Message
  • $obj->labels() β€” inherited, see "Flags" in Mail::Message
  • $obj->labelsToStatus() β€” inherited, see "Flags" in Mail::Message
  • $obj->modified( [BOOLEAN] ) β€” inherited, see "Flags" in Mail::Message
  • $obj->statusToLabels() β€” inherited, see "Flags" in Mail::Message

πŸ“œ The whole message as text πŸ“œ

Extends "The whole message as text" in Mail::Box::Net::Message.

  • $obj->file() β€” inherited, see "The whole message as text" in Mail::Message::Construct::Text
  • $obj->lines() β€” inherited, see "The whole message as text" in Mail::Message::Construct::Text
  • $obj->printStructure( [$fh|undef],[$indent] ) β€” inherited, see "The whole message as text" in Mail::Message::Construct::Text
  • $obj->string() β€” inherited, see "The whole message as text" in Mail::Message::Construct::Text

πŸ”§ Internals πŸ”§

Extends "Internals" in Mail::Box::Net::Message.

  • $obj->clonedFrom() β€” inherited, see "Internals" in Mail::Message
  • $class->coerce($message, %options) β€” inherited, see "Internals" in Mail::Message
  • $obj->diskDelete() β€” inherited, see "Internals" in Mail::Box::Message
  • $obj->isDelayed() β€” inherited, see "Internals" in Mail::Message
  • $obj->isTrusted() β€” inherited, see "Internals" in Mail::Message
  • $obj->loadBody() β€” inherited, see "Internals" in Mail::Box::Net::Message
  • $obj->readBody( $parser, $head, [$bodytype] ) β€” inherited, see "Internals" in Mail::Box::Message
  • $obj->readFromParser( $parser, [$bodytype] ) β€” inherited, see "Internals" in Mail::Message
  • $obj->readHead( $parser, [$class] ) β€” inherited, see "Internals" in Mail::Message
  • $obj->recursiveRebuildPart($part, %options) β€” inherited, see "Internals" in Mail::Message::Construct::Rebuild
  • $obj->storeBody($body) β€” inherited, see "Internals" in Mail::Message
  • $obj->takeMessageId( [STRING] ) β€” inherited, see "Internals" in Mail::Message

😭 Error handling 😭

Extends "Error handling" in Mail::Box::Net::Message.

  • $obj->AUTOLOAD() β€” inherited, see "METHODS" in Mail::Message::Construct
  • $obj->notImplemented() β€” inherited, see "Error handling" in Mail::Reporter
  • $any->shortSize( [$value] ) β€” inherited, see "Error handling" in Mail::Message
  • $obj->shortString() β€” inherited, see "Error handling" in Mail::Message

🌈 Cleanup 🌈

Extends "Cleanup" in Mail::Box::Net::Message.

  • $obj->DESTROY() β€” inherited, see "Cleanup" in Mail::Reporter
  • $obj->destruct() β€” inherited, see "Cleanup" in Mail::Box::Message

πŸ’œ DETAILS πŸ’œ

Extends "DETAILS" in Mail::Box::Net::Message.

πŸ’€ DIAGNOSTICS πŸ’€

okay bestie, this is the part where the module is basically yelling at you. every one of these is a real error/warning it can throw, and each one tells you which method "cast" it (that's just fancy talk for "this is the method that threw it"). let's go, one by one πŸ’…

  • Error: Cannot include forward source as $kind. bestie the forward(include) option got a value it does not recognize 😭. the only valid choices are "NO", "INLINE", "ATTACH", and "ENCAPSULATE". thrown by forward().
  • Error: No default mailer found to send message. the send() mechanism literally did not have enough info to auto-find a mail transfer agent to send your message 🫠. so specify a mailer explicitly with the via options, mkay? thrown by send().
  • Error: cannot coerce a $type object into a $me object. it tried to turn one kind of object into another and it simply did not work. thrown by coerce().
  • Error: cannot include reply source as $kind. unknown value passed to the "include" option of reply(). the valid choices are "NO", "INLINE", and "ATTACH" β€” that's it, that's the list ✨. thrown by reply().
  • Error: cannot read message from a $source. it could not read the message from that source, periodt. thrown by read().
  • Error: class $package does not implement method $method. okay this one is fatal, pay attention 😳 β€” the specific $package (or one of its superclasses) just does not implement this method where it's supposed to. it means some other related classes do implement this method, but the class you're holding does not. so you should probably dig into this and probably tell the author of the package about it. thrown by notImplemented().
  • Error: coercion starts with some object, not '$type'. the coercion started with something that wasn't what you said it was. thrown by coerce().
  • Error: method bounce requires To, Cc, or Bcc. the bounce() method forwards a received message off to someone else with no modification, so you absolutely must specify its new destination 🎯. if you feel the urge not to specify any destination, you're probably looking for reply() instead. and if you wanna modify the content, use forward(). thrown by bounce().
  • Error: method forwardAttach requires a preamble. no preamble, no forwardAttach(). thrown by forwardAttach().
  • Error: method forwardEncapsulate requires a preamble. same energy β€” it needs a preamble. thrown by forwardEncapsulate().
  • Error: method forwardNo requires a To. forwardNo() wants a To. give it one πŸ™ˆ. thrown by forwardNo().
  • Error: method forwardNo requires a body. and also a body. thrown by forwardNo().
  • Error: no rebuild rule $name defined. there's no rebuild rule by that name, so like... nothing to rebuild with 🀷. thrown by rebuild().
  • Error: only build() Mail::Message's; they are not in a folder yet. okay this one needs a lil story time πŸ“ β€” you might wanna construct a message to be stored in some kind of folder, but bestie you gotta do that in two steps. first, create a normal Mail::Message, and then add it to the folder. during this Mail::Box::addMessage() process, the message will get coerce()-d into the right message type, adding storage information and the like. thrown by build().
  • Error: please install Email::Simple. go install it bestie. thrown by coerce().
  • Error: please install MIME::Entity. also install this one. thrown by coerce().
  • Error: please install Mail::Internet. and this one. thrown by coerce().
  • Error: select parts via '$what'? the part selection was not it. thrown by parts().
  • Warning: skipped unknown key '$key' in build. just a warning, not fatal β€” but it skipped an unknown key during build πŸ‘€. thrown by build().
  • Error: unable to read delayed body for $msgid. couldn't read the delayed body for that message id. thrown by loadBody().
  • Error: unable to read delayed head for $msgid. couldn't read the delayed head either. thrown by loadBody().

πŸ‘€ SEE ALSO πŸ‘€

this module is part of Mail-Box-POP3 version 4.02, built on April 10, 2026. if you wanna go touch grass on the internet about it, the website is http://perl.overmeer.net/CPAN/ 🌈


πŸ“œ LICENSE πŸ“œ

for contributors, see file ChangeLog.

this software is copyright (c) 2001-2026 by Mark Overmeer.

it's free software 🫢 β€” you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.


and that's the whole page, bestie!! you made it to the end and honestly? iconic behavior πŸ‘‘πŸ’– this was Mail::...essage(3pm), dropped from perl v5.40.1 on 2026-05-09 β€” go forth and slay your mail objects, no cap βœ¨πŸ¦‹

πŸ“¦ where this page comes from