1Mail::Message::Field::UUnssetrruCcotnutrreidb(u3t)ed PerMlaiDlo:c:uMmeesnstaagtei:o:nField::Unstructured(3)
2
3
4

NAME

6       Mail::Message::Field::Unstructured - smart unstructured field
7

INHERITANCE

9        Mail::Message::Field::Unstructured
10          is a Mail::Message::Field::Full
11          is a Mail::Message::Field
12          is a Mail::Reporter
13

SYNOPSIS

15        my $f = Mail::Message::Field::Unstructured->new('Comments', 'hi!');
16

DESCRIPTION

18       Unstructured fields do contain information which is not restricted in
19       any way.  RFC2822 defines some unstructured fields, but by default all
20       unknown fields are unstructured as well.  Things like attributes and
21       comments have no meaning for unstructured fields, but encoding does.
22
23       Extends "DESCRIPTION" in Mail::Message::Field::Full.
24

OVERLOADED

26       Extends "OVERLOADED" in Mail::Message::Field::Full.
27
28       overload: ""
29           Inherited, see "OVERLOADED" in Mail::Message::Field
30
31       overload: 0+
32           Inherited, see "OVERLOADED" in Mail::Message::Field
33
34       overload: <=>
35           Inherited, see "OVERLOADED" in Mail::Message::Field
36
37       overload: bool
38           Inherited, see "OVERLOADED" in Mail::Message::Field
39
40       overload: cmp
41           Inherited, see "OVERLOADED" in Mail::Message::Field
42
43       overload: stringification
44           Inherited, see "OVERLOADED" in Mail::Message::Field::Full
45

METHODS

47       Extends "METHODS" in Mail::Message::Field::Full.
48
49   Constructors
50       Extends "Constructors" in Mail::Message::Field::Full.
51
52       $obj->clone()
53           Inherited, see "Constructors" in Mail::Message::Field
54
55       Mail::Message::Field::Unstructured->from($field, %options)
56           Inherited, see "Constructors" in Mail::Message::Field::Full
57
58       Mail::Message::Field::Unstructured->new($data)
59           When the $data is specified as single line, the content part is
60           considered to be correcly (character) encoded and escaped.
61           Typically, it is a line as read from file.  The folding of the line
62           is kept as is.
63
64           In case more than one argument is provided, the second is
65           considered the BODY.  Attributes and other special things are not
66           defined for unstructured fields, and therefore not valid options.
67           The BODY can be a single string, a single OBJECT, or an array of
68           OBJECTS.  The objects are stringified (into a comma separated
69           list).  Each BODY element is interpreted with the specified
70           encoding.
71
72           When the BODY is empty, the construction of the object fails:
73           "undef" is returned.
74
75            -Option  --Defined in                --Default
76             charset   Mail::Message::Field::Full  undef
77             encoding  Mail::Message::Field::Full  'q'
78             force     Mail::Message::Field::Full  false
79             language  Mail::Message::Field::Full  undef
80             log       Mail::Reporter              'WARNINGS'
81             trace     Mail::Reporter              'WARNINGS'
82
83           charset => STRING
84           encoding => 'q'|'Q'|'b'|'B'
85           force => BOOLEAN
86           language => STRING
87           log => LEVEL
88           trace => LEVEL
89
90           example:
91
92            my $s = Mail::Message::Field::Unstructured->new('Comment', 'Hi!');
93
94            # Use autodetect
95            my $s = Mail::Message::Field::Full->new('Comment', 'Hi!');
96            my $s = Mail::Message::Field::Full->new('Comment: Hi!');
97
98   The field
99       Extends "The field" in Mail::Message::Field::Full.
100
101       $obj->isStructured()
102       Mail::Message::Field::Unstructured->isStructured()
103           Inherited, see "The field" in Mail::Message::Field
104
105       $obj->length()
106           Inherited, see "The field" in Mail::Message::Field
107
108       $obj->nrLines()
109           Inherited, see "The field" in Mail::Message::Field
110
111       $obj->print( [$fh] )
112           Inherited, see "The field" in Mail::Message::Field
113
114       $obj->size()
115           Inherited, see "The field" in Mail::Message::Field
116
117       $obj->string( [$wrap] )
118           Inherited, see "The field" in Mail::Message::Field
119
120       $obj->toDisclose()
121           Inherited, see "The field" in Mail::Message::Field
122
123   Access to the name
124       Extends "Access to the name" in Mail::Message::Field::Full.
125
126       $obj->Name()
127           Inherited, see "Access to the name" in Mail::Message::Field
128
129       $obj->name()
130           Inherited, see "Access to the name" in Mail::Message::Field
131
132       $obj->wellformedName( [STRING] )
133           Inherited, see "Access to the name" in Mail::Message::Field
134
135   Access to the body
136       Extends "Access to the body" in Mail::Message::Field::Full.
137
138       $obj->body()
139           Inherited, see "Access to the body" in Mail::Message::Field
140
141       $obj->decodedBody(%options)
142           Inherited, see "Access to the body" in Mail::Message::Field::Full
143
144       $obj->folded()
145           Inherited, see "Access to the body" in Mail::Message::Field
146
147       $obj->foldedBody( [$body] )
148           Inherited, see "Access to the body" in Mail::Message::Field
149
150       $obj->stripCFWS( [STRING] )
151       Mail::Message::Field::Unstructured->stripCFWS( [STRING] )
152           Inherited, see "Access to the body" in Mail::Message::Field
153
154       $obj->unfoldedBody( [$body, [$wrap]] )
155           Inherited, see "Access to the body" in Mail::Message::Field
156
157   Access to the content
158       Extends "Access to the content" in Mail::Message::Field::Full.
159
160       $obj->addresses()
161           Inherited, see "Access to the content" in Mail::Message::Field
162
163       $obj->attribute( $name, [$value] )
164           Inherited, see "Access to the content" in Mail::Message::Field
165
166       $obj->attributes()
167           Inherited, see "Access to the content" in Mail::Message::Field
168
169       $obj->beautify()
170           Inherited, see "Access to the content" in
171           Mail::Message::Field::Full
172
173       $obj->comment( [STRING] )
174           Inherited, see "Access to the content" in Mail::Message::Field
175
176       $obj->createComment(STRING, %options)
177       Mail::Message::Field::Unstructured->createComment(STRING, %options)
178           Inherited, see "Access to the content" in
179           Mail::Message::Field::Full
180
181       $obj->createPhrase(STRING, %options)
182       Mail::Message::Field::Unstructured->createPhrase(STRING, %options)
183           Inherited, see "Access to the content" in
184           Mail::Message::Field::Full
185
186       $obj->study()
187           Inherited, see "Access to the content" in Mail::Message::Field
188
189       $obj->toDate( [$time] )
190       Mail::Message::Field::Unstructured->toDate( [$time] )
191           Inherited, see "Access to the content" in Mail::Message::Field
192
193       $obj->toInt()
194           Inherited, see "Access to the content" in Mail::Message::Field
195
196   Other methods
197       Extends "Other methods" in Mail::Message::Field::Full.
198
199       $obj->dateToTimestamp(STRING)
200       Mail::Message::Field::Unstructured->dateToTimestamp(STRING)
201           Inherited, see "Other methods" in Mail::Message::Field
202
203   Internals
204       Extends "Internals" in Mail::Message::Field::Full.
205
206       $obj->consume( $line | <$name,<$body|$objects>> )
207           Inherited, see "Internals" in Mail::Message::Field
208
209       $obj->decode(STRING, %options)
210       Mail::Message::Field::Unstructured->decode(STRING, %options)
211           Inherited, see "Internals" in Mail::Message::Field::Full
212
213       $obj->defaultWrapLength( [$length] )
214           Inherited, see "Internals" in Mail::Message::Field
215
216       $obj->encode(STRING, %options)
217           Inherited, see "Internals" in Mail::Message::Field::Full
218
219       $obj->fold( $name, $body, [$maxchars] )
220       Mail::Message::Field::Unstructured->fold( $name, $body, [$maxchars] )
221           Inherited, see "Internals" in Mail::Message::Field
222
223       $obj->setWrapLength( [$length] )
224           Inherited, see "Internals" in Mail::Message::Field
225
226       $obj->stringifyData(STRING|ARRAY|$objects)
227           Inherited, see "Internals" in Mail::Message::Field
228
229       $obj->unfold(STRING)
230           Inherited, see "Internals" in Mail::Message::Field
231
232   Parsing
233       Extends "Parsing" in Mail::Message::Field::Full.
234
235       $obj->consumeComment(STRING)
236       Mail::Message::Field::Unstructured->consumeComment(STRING)
237           Inherited, see "Parsing" in Mail::Message::Field::Full
238
239       $obj->consumeDotAtom(STRING)
240           Inherited, see "Parsing" in Mail::Message::Field::Full
241
242       $obj->consumePhrase(STRING)
243       Mail::Message::Field::Unstructured->consumePhrase(STRING)
244           Inherited, see "Parsing" in Mail::Message::Field::Full
245
246       $obj->parse(STRING)
247           Inherited, see "Parsing" in Mail::Message::Field::Full
248
249       $obj->produceBody()
250           Inherited, see "Parsing" in Mail::Message::Field::Full
251
252   Error handling
253       Extends "Error handling" in Mail::Message::Field::Full.
254
255       $obj->AUTOLOAD()
256           Inherited, see "Error handling" in Mail::Reporter
257
258       $obj->addReport($object)
259           Inherited, see "Error handling" in Mail::Reporter
260
261       $obj->defaultTrace( [$level]|[$loglevel, $tracelevel]|[$level,
262       $callback] )
263       Mail::Message::Field::Unstructured->defaultTrace( [$level]|[$loglevel,
264       $tracelevel]|[$level, $callback] )
265           Inherited, see "Error handling" in Mail::Reporter
266
267       $obj->errors()
268           Inherited, see "Error handling" in Mail::Reporter
269
270       $obj->log( [$level, [$strings]] )
271       Mail::Message::Field::Unstructured->log( [$level, [$strings]] )
272           Inherited, see "Error handling" in Mail::Reporter
273
274       $obj->logPriority($level)
275       Mail::Message::Field::Unstructured->logPriority($level)
276           Inherited, see "Error handling" in Mail::Reporter
277
278       $obj->logSettings()
279           Inherited, see "Error handling" in Mail::Reporter
280
281       $obj->notImplemented()
282           Inherited, see "Error handling" in Mail::Reporter
283
284       $obj->report( [$level] )
285           Inherited, see "Error handling" in Mail::Reporter
286
287       $obj->reportAll( [$level] )
288           Inherited, see "Error handling" in Mail::Reporter
289
290       $obj->trace( [$level] )
291           Inherited, see "Error handling" in Mail::Reporter
292
293       $obj->warnings()
294           Inherited, see "Error handling" in Mail::Reporter
295
296   Cleanup
297       Extends "Cleanup" in Mail::Message::Field::Full.
298
299       $obj->DESTROY()
300           Inherited, see "Cleanup" in Mail::Reporter
301

DETAILS

303       Extends "DETAILS" in Mail::Message::Field::Full.
304

DIAGNOSTICS

306       Warning: Field content is not numerical: $content
307           The numeric value of a field is requested (for instance the "Lines"
308           or "Content-Length" fields should be numerical), however the data
309           contains weird characters.
310
311       Warning: Illegal character in charset '$charset'
312           The field is created with an utf8 string which only contains data
313           from the specified character set.  However, that character set can
314           never be a valid name because it contains characters which are not
315           permitted.
316
317       Warning: Illegal character in field name $name
318           A new field is being created which does contain characters not
319           permitted by the RFCs.  Using this field in messages may break
320           other e-mail clients or transfer agents, and therefore mutulate or
321           extinguish your message.
322
323       Warning: Illegal character in language '$lang'
324           The field is created with data which is specified to be in a
325           certain language, however, the name of the language cannot be
326           valid: it contains characters which are not permitted by the RFCs.
327
328       Warning: Illegal encoding '$encoding', used 'q'
329           The RFCs only permit base64 ("b " or "B ") or quoted-printable ("q"
330           or "Q") encoding.  Other than these four options are illegal.
331
332       Error: Package $package does not implement $method.
333           Fatal error: the specific package (or one of its superclasses) does
334           not implement this method where it should. This message means that
335           some other related classes do implement this method however the
336           class at hand does not.  Probably you should investigate this and
337           probably inform the author of the package.
338

SEE ALSO

340       This module is part of Mail-Message distribution version 3.012, built
341       on February 11, 2022. Website: http://perl.overmeer.net/CPAN/
342

LICENSE

344       Copyrights 2001-2022 by [Mark Overmeer <markov@cpan.org>]. For other
345       contributors see ChangeLog.
346
347       This program is free software; you can redistribute it and/or modify it
348       under the same terms as Perl itself.  See http://dev.perl.org/licenses/
349
350
351
352perl v5.34.0                      2022-03-M0a1il::Message::Field::Unstructured(3)
Impressum