1        Cone©
2
3MAIL::HEADER::ADDRES(3x)Cone: COnsole Newsreader And EMAIL::HEADER::ADDRES(3x)
4
5
6

NAME

8       mail::Header::addresslist - An E-mail header that contains addresses.
9

SYNOPSIS

11       #include <libmail/headers.H>
12
13       std::vector<mail::emailAddress> address_list;
14       mail::emailAddress addr;
15
16       mail::Header::addresslist tohdr("To", address_list);
17
18       mail::Header::addresslist cchdr("Cc")("John", "john@example.com")
19                                            ("Tom", "tom@example.com")
20                                            (addr);
21
22       std::cout << tohdr.toString();
23
24

USAGE

26       This class creates a header that contains addresses, such as the “To:”
27       or the “Cc:” header. Two arguments are provided to the constructor: the
28       header's name, and a vector containing the addresses.
29
30       This is not the appropriate class to create structured MIME headers.
31       Use mail::Header::mime(3x) to create structured MIME headers.
32
33       The toString() returns the header as a single text string: “name:
34       value”. Long headers are folded accordingly.
35
36   Dynamic address list generation
37       This class has an alternative constructor that receives a single
38       parameter: the header's name, which initializes an empty address list.
39       The address list is populated by repeatedly calling the “()” operator.
40
41       One version of the “()” operator receives the explicit name and address
42       components of an E-mail address. Alternatively, a mail::emailAddress
43       object may be provided.
44

SEE ALSO

46       mail::Header::encoded(3x), mail::Header::list(3x),
47       mail::Header::mime(3x), mail::Header::plain(3x).
48

AUTHOR

50       Sam Varshavchik
51
52
53
54Cone©                             08/25/2016          MAIL::HEADER::ADDRES(3x)
Impressum