1Mail::Message::Dummy(3)User Contributed Perl DocumentatioMnail::Message::Dummy(3)
2
3
4
6 Mail::Message::Dummy - a placeholder for a missing messages
7
9 Mail::Message::Dummy
10 is a Mail::Message
11 is a Mail::Reporter
12
15 Dummy messages are used by modules which maintain ordered lists of
16 messages, usually based on message-id. A good example is
17 Mail::Box::Thread::Manager, which detects related messages by scanning
18 the known message headers for references to other messages. As long as
19 the referenced messages are not found inside the mailbox, their place
20 is occupied by a dummy.
21
22 Be careful when using modules which may create dummies. Before trying
23 to access the header or body use isDummy() to check if the message is a
24 dummy message.
25
26 Extends "DESCRIPTION" in Mail::Message.
27
29 Extends "METHODS" in Mail::Message.
30
31 Constructors
32 Extends "Constructors" in Mail::Message.
33
34 $obj->clone(%options)
35 Inherited, see "Constructors" in Mail::Message
36
37 Mail::Message::Dummy->new($message_id, %options)
38 Create a new dummy message to occupy the space for a real message
39 with the specified $message_id.
40
41 -Option --Defined in --Default
42 body Mail::Message <not used>
43 body_type Mail::Message Mail::Message::Body::Lines
44 deleted Mail::Message <false>
45 field_type Mail::Message <not used>
46 head Mail::Message <not used>
47 head_type Mail::Message <not used>
48 labels Mail::Message {}
49 log Mail::Reporter 'WARNINGS'
50 messageId Mail::Message <required>
51 modified Mail::Message <always false>
52 trace Mail::Reporter 'WARNINGS'
53 trusted Mail::Message <always true>
54
55 body => OBJECT
56 body_type => CLASS
57 deleted => BOOLEAN
58 field_type => CLASS
59 head => OBJECT
60 head_type => CLASS
61 labels => ARRAY|HASH
62 log => LEVEL
63 messageId => STRING
64 modified => BOOLEAN
65 trace => LEVEL
66 trusted => BOOLEAN
67
68 example:
69
70 my $message = Mail::Message::Dummy->new($msgid);
71 if($message->isDummy) {...}
72
73 Constructing a message
74 Extends "Constructing a message" in Mail::Message.
75
76 $obj->bounce( [<$rg_object|%options>] )
77 Inherited, see "Constructing a message" in
78 Mail::Message::Construct::Bounce
79
80 Mail::Message::Dummy->build( [$message|$part|$body], $content )
81 Inherited, see "Constructing a message" in
82 Mail::Message::Construct::Build
83
84 Mail::Message::Dummy->buildFromBody($body, [$head], $headers)
85 Inherited, see "Constructing a message" in
86 Mail::Message::Construct::Build
87
88 $obj->forward(%options)
89 Inherited, see "Constructing a message" in
90 Mail::Message::Construct::Forward
91
92 $obj->forwardAttach(%options)
93 Inherited, see "Constructing a message" in
94 Mail::Message::Construct::Forward
95
96 $obj->forwardEncapsulate(%options)
97 Inherited, see "Constructing a message" in
98 Mail::Message::Construct::Forward
99
100 $obj->forwardInline(%options)
101 Inherited, see "Constructing a message" in
102 Mail::Message::Construct::Forward
103
104 $obj->forwardNo(%options)
105 Inherited, see "Constructing a message" in
106 Mail::Message::Construct::Forward
107
108 $obj->forwardPostlude()
109 Inherited, see "Constructing a message" in
110 Mail::Message::Construct::Forward
111
112 $obj->forwardPrelude()
113 Inherited, see "Constructing a message" in
114 Mail::Message::Construct::Forward
115
116 $obj->forwardSubject(STRING)
117 Inherited, see "Constructing a message" in
118 Mail::Message::Construct::Forward
119
120 Mail::Message::Dummy->read($fh|STRING|SCALAR|ARRAY, %options)
121 Inherited, see "Constructing a message" in
122 Mail::Message::Construct::Read
123
124 $obj->rebuild(%options)
125 Inherited, see "Constructing a message" in
126 Mail::Message::Construct::Rebuild
127
128 $obj->reply(%options)
129 Inherited, see "Constructing a message" in
130 Mail::Message::Construct::Reply
131
132 $obj->replyPrelude( [STRING|$field|$address|ARRAY-$of-$things] )
133 Inherited, see "Constructing a message" in
134 Mail::Message::Construct::Reply
135
136 $obj->replySubject(STRING)
137 Mail::Message::Dummy->replySubject(STRING)
138 Inherited, see "Constructing a message" in
139 Mail::Message::Construct::Reply
140
141 The message
142 Extends "The message" in Mail::Message.
143
144 $obj->container()
145 Inherited, see "The message" in Mail::Message
146
147 $obj->isDummy()
148 Inherited, see "The message" in Mail::Message
149
150 $obj->isPart()
151 Inherited, see "The message" in Mail::Message
152
153 $obj->messageId()
154 Inherited, see "The message" in Mail::Message
155
156 $obj->partNumber()
157 Inherited, see "The message" in Mail::Message
158
159 $obj->print( [$fh] )
160 Inherited, see "The message" in Mail::Message
161
162 $obj->send( [$mailer], %options )
163 Inherited, see "The message" in Mail::Message
164
165 $obj->size()
166 Inherited, see "The message" in Mail::Message
167
168 $obj->toplevel()
169 Inherited, see "The message" in Mail::Message
170
171 $obj->write( [$fh] )
172 Inherited, see "The message" in Mail::Message
173
174 The header
175 Extends "The header" in Mail::Message.
176
177 $obj->bcc()
178 Inherited, see "The header" in Mail::Message
179
180 $obj->cc()
181 Inherited, see "The header" in Mail::Message
182
183 $obj->date()
184 Inherited, see "The header" in Mail::Message
185
186 $obj->destinations()
187 Inherited, see "The header" in Mail::Message
188
189 $obj->from()
190 Inherited, see "The header" in Mail::Message
191
192 $obj->get($fieldname)
193 Inherited, see "The header" in Mail::Message
194
195 $obj->guessTimestamp()
196 Inherited, see "The header" in Mail::Message
197
198 $obj->head(...)
199 $obj->nrLines()
200 Inherited, see "The header" in Mail::Message
201
202 $obj->sender()
203 Inherited, see "The header" in Mail::Message
204
205 $obj->study($fieldname)
206 Inherited, see "The header" in Mail::Message
207
208 $obj->subject()
209 Inherited, see "The header" in Mail::Message
210
211 $obj->timestamp()
212 Inherited, see "The header" in Mail::Message
213
214 $obj->to()
215 Inherited, see "The header" in Mail::Message
216
217 The body
218 Extends "The body" in Mail::Message.
219
220 $obj->body( [$body] )
221 Inherited, see "The body" in Mail::Message
222
223 $obj->contentType()
224 Inherited, see "The body" in Mail::Message
225
226 $obj->decoded(%options)
227 Inherited, see "The body" in Mail::Message
228
229 $obj->encode(%options)
230 Inherited, see "The body" in Mail::Message
231
232 $obj->isMultipart()
233 Inherited, see "The body" in Mail::Message
234
235 $obj->isNested()
236 Inherited, see "The body" in Mail::Message
237
238 $obj->parts( [<'ALL'|'ACTIVE'|'DELETED'|'RECURSE'|$filter>] )
239 Inherited, see "The body" in Mail::Message
240
241 Flags
242 Extends "Flags" in Mail::Message.
243
244 $obj->delete()
245 Inherited, see "Flags" in Mail::Message
246
247 $obj->deleted( [BOOLEAN] )
248 Inherited, see "Flags" in Mail::Message
249
250 $obj->isDeleted()
251 Inherited, see "Flags" in Mail::Message
252
253 $obj->isModified()
254 Inherited, see "Flags" in Mail::Message
255
256 $obj->label($label|PAIRS)
257 Inherited, see "Flags" in Mail::Message
258
259 $obj->labels()
260 Inherited, see "Flags" in Mail::Message
261
262 $obj->labelsToStatus()
263 Inherited, see "Flags" in Mail::Message
264
265 $obj->modified( [BOOLEAN] )
266 Inherited, see "Flags" in Mail::Message
267
268 $obj->statusToLabels()
269 Inherited, see "Flags" in Mail::Message
270
271 The whole message as text
272 Extends "The whole message as text" in Mail::Message.
273
274 $obj->file()
275 Inherited, see "The whole message as text" in
276 Mail::Message::Construct::Text
277
278 $obj->lines()
279 Inherited, see "The whole message as text" in
280 Mail::Message::Construct::Text
281
282 $obj->printStructure( [$fh|undef],[$indent] )
283 Inherited, see "The whole message as text" in
284 Mail::Message::Construct::Text
285
286 $obj->string()
287 Inherited, see "The whole message as text" in
288 Mail::Message::Construct::Text
289
290 Internals
291 Extends "Internals" in Mail::Message.
292
293 $obj->clonedFrom()
294 Inherited, see "Internals" in Mail::Message
295
296 Mail::Message::Dummy->coerce($message, %options)
297 Inherited, see "Internals" in Mail::Message
298
299 $obj->isDelayed()
300 Inherited, see "Internals" in Mail::Message
301
302 $obj->readBody( $parser, $head, [$bodytype] )
303 Inherited, see "Internals" in Mail::Message
304
305 $obj->readFromParser( $parser, [$bodytype] )
306 Inherited, see "Internals" in Mail::Message
307
308 $obj->readHead( $parser, [$class] )
309 Inherited, see "Internals" in Mail::Message
310
311 $obj->recursiveRebuildPart($part, %options)
312 Inherited, see "Internals" in Mail::Message::Construct::Rebuild
313
314 $obj->storeBody($body)
315 Inherited, see "Internals" in Mail::Message
316
317 $obj->takeMessageId( [STRING] )
318 Inherited, see "Internals" in Mail::Message
319
320 Error handling
321 Extends "Error handling" in Mail::Message.
322
323 $obj->AUTOLOAD()
324 Inherited, see "METHODS" in Mail::Message::Construct
325
326 $obj->addReport($object)
327 Inherited, see "Error handling" in Mail::Reporter
328
329 $obj->defaultTrace( [$level]|[$loglevel, $tracelevel]|[$level,
330 $callback] )
331 Mail::Message::Dummy->defaultTrace( [$level]|[$loglevel,
332 $tracelevel]|[$level, $callback] )
333 Inherited, see "Error handling" in Mail::Reporter
334
335 $obj->errors()
336 Inherited, see "Error handling" in Mail::Reporter
337
338 $obj->log( [$level, [$strings]] )
339 Mail::Message::Dummy->log( [$level, [$strings]] )
340 Inherited, see "Error handling" in Mail::Reporter
341
342 $obj->logPriority($level)
343 Mail::Message::Dummy->logPriority($level)
344 Inherited, see "Error handling" in Mail::Reporter
345
346 $obj->logSettings()
347 Inherited, see "Error handling" in Mail::Reporter
348
349 $obj->notImplemented()
350 Inherited, see "Error handling" in Mail::Reporter
351
352 $obj->report( [$level] )
353 Inherited, see "Error handling" in Mail::Reporter
354
355 $obj->reportAll( [$level] )
356 Inherited, see "Error handling" in Mail::Reporter
357
358 $obj->shortSize( [$value] )
359 Mail::Message::Dummy->shortSize( [$value] )
360 Inherited, see "Error handling" in Mail::Message
361
362 $obj->shortString()
363 Inherited, see "Error handling" in Mail::Message
364
365 $obj->trace( [$level] )
366 Inherited, see "Error handling" in Mail::Reporter
367
368 $obj->warnings()
369 Inherited, see "Error handling" in Mail::Reporter
370
371 Cleanup
372 Extends "Cleanup" in Mail::Message.
373
374 $obj->DESTROY()
375 Inherited, see "Cleanup" in Mail::Reporter
376
377 $obj->destruct()
378 Inherited, see "Cleanup" in Mail::Message
379
381 Extends "DETAILS" in Mail::Message.
382
384 Error: Cannot coerce a $class object into a $class object
385 Error: Cannot include forward source as $include.
386 Unknown alternative for the forward(include). Valid choices are
387 "NO", "INLINE", "ATTACH", and "ENCAPSULATE".
388
389 Error: Cannot include reply source as $include.
390 Unknown alternative for the "include" option of reply(). Valid
391 choices are "NO", "INLINE", and "ATTACH".
392
393 Error: Message-Id is required for a dummy.
394 A dummy message occupies the place for a real message. When a
395 dummy is created, the id of the message which place it is holding
396 must be known.
397
398 Error: Method bounce requires To, Cc, or Bcc
399 The message bounce() method forwards a received message off to
400 someone else without modification; you must specified it's new
401 destination. If you have the urge not to specify any destination,
402 you probably are looking for reply(). When you wish to modify the
403 content, use forward().
404
405 Error: Method forwardAttach requires a preamble
406 Error: Method forwardEncapsulate requires a preamble
407 Error: No address to create forwarded to.
408 If a forward message is created, a destination address must be
409 specified.
410
411 Error: No default mailer found to send message.
412 The message send() mechanism had not enough information to
413 automatically find a mail transfer agent to sent this message.
414 Specify a mailer explicitly using the "via" options.
415
416 Error: No rebuild rule $name defined.
417 Error: Only build() Mail::Message's; they are not in a folder yet
418 You may wish to construct a message to be stored in a some kind of
419 folder, but you need to do that in two steps. First, create a
420 normal Mail::Message, and then add it to the folder. During this
421 Mail::Box::addMessage() process, the message will get coerce()-d
422 into the right message type, adding storage information and the
423 like.
424
425 Error: Package $package does not implement $method.
426 Fatal error: the specific package (or one of its superclasses) does
427 not implement this method where it should. This message means that
428 some other related classes do implement this method however the
429 class at hand does not. Probably you should investigate this and
430 probably inform the author of the package.
431
432 Error: You cannot take the head/body of a dummy message
433 Dummy messages are place-holders in message threads: the thread
434 detected the existence of the message, because it found the
435 message-id in a Reply-To or References field, however it did not
436 find the header and body of the message yet. Use isDummy() to
437 check whether the thread node returned a dummy or not.
438
439 Error: coercion starts with some object
440
442 This module is part of Mail-Box distribution version 3.009, built on
443 August 18, 2020. Website: http://perl.overmeer.net/CPAN/
444
446 Copyrights 2001-2020 by [Mark Overmeer]. For other contributors see
447 ChangeLog.
448
449 This program is free software; you can redistribute it and/or modify it
450 under the same terms as Perl itself. See http://dev.perl.org/licenses/
451
452
453
454perl v5.36.0 2023-01-20 Mail::Message::Dummy(3)