/usr/share/doc/libbobcat2-dev/man/mailheaders.3.html is in libbobcat-dev 2.20.01-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 | <html><head>
<title>FBB::MailHeaders</title>
<link rev="made" href="mailto:Frank B. Brokken: f.b.brokken@rug.nl">
</head>
<body text="#27408B" bgcolor="#FFFAF0">
<hr>
<h1>FBB::MailHeaders</h1>
<h2>libbobcat1-dev_2.20.01-x.tar.gz</h2>
<h2>2005-2011</h2>
<html><head>
<link rev="made" href="mailto:Frank B. Brokken: f.b.brokken@rug.nl">
</head>
<body text="#27408B" bgcolor="#FFFAF0">
<hr>
<h1></h1>
<html><head>
<title>FBB::MailHeaders(3bobcat)</title>
<link rev="made" href="mailto:Frank B. Brokken: f.b.brokken@rug.nl">
</head>
<body text="#27408B" bgcolor="#FFFAF0">
<hr>
<h1>FBB::MailHeaders(3bobcat)</h1>
<h2>libbobcat1-dev_2.20.01-x.tar.gz SMTP Mail Headers</h2>
<h2>2005-2011</h2>
<p>
<h2>NAME</h2>FBB::MailHeaders - Handles SMTP Mail Headers
<p>
<h2>SYNOPSIS</h2>
<strong>#include <bobcat/mailheaders></strong><br>
Linking option: <em>-lbobcat</em>
<p>
<h2>DESCRIPTION</h2>
<p>
<strong>FBB::MailHeaders</strong> objects extract header lines from e-mail. Reading
stops at (and including) the first blank line, which becomes the last element
of the <strong>FBB::MailHeaders</strong> object, interpreted as a <strong>vector</strong>. The actual
e-mail content is therefore left unread on the file containing the e-mail.
<p>
Each line stored in a <strong>MailHeaders</strong> object represents a complete header
line. Headers continuing over multiple input lines are concatenated to a
single line retrievable from <strong>MailHeaders</strong> objects, separated from each
other by <em>'\n'</em> (newline) characters. The last line to join a multi-line
header is not terminated by a newline character.
<p>
<h2>NAMESPACE</h2>
<strong>FBB</strong><br>
All constructors, members, operators and manipulators, mentioned in this
man-page, are defined in the namespace <strong>FBB</strong>.
<p>
<h2>INHERITS FROM</h2>
-
<p>
<h2>ENUMERATIONS</h2>
The following enumerations and enumeration values can be used with the
class <strong>FBB::MailHeaders</strong>:
<p>
<strong>enum Mode</strong><br>
This enumeration defines two values:
<ul>
<li> <strong>READ</strong>:<br>
When this value is specified at construction time, e-mail is
immediately read by the constructor.
<li> <strong>DONT_READ</strong>:<br>
When this value is specified at construction time, e-mail is read
using the <em>read</em> member (see below).
</ul>
<p>
<strong>enum Match</strong><br>
This enumeration defines the following values:
<ul>
<li> <strong>FULL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
headers must exactly match a specified header name.
<li> <strong>INITIAL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
initial part of the headers must match the specified header text.
<li> <strong>PARTIAL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
headers must contain the specified header text.
<li> <strong>CASE_FULL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
headers must exactly match a specified header name. The matching is performed
case insensititvely.
<li> <strong>CASE_INITIAL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
initial part of the headers must match the specified header text. The matching
is performed case insensititvely.
<li> <strong>CASE_PARTIAL</strong>:<br>
Used by <em>setHeaderIterator</em> (see below) to indicate that the
headers must contain the specified header text. The matching is performed case
insensititvely.
</ul>
<p>
<h2>NESTED TYPES</h2>
<p>
The class <em>MailHeaders</em> defines the following types:
<ul>
<li> <strong>const_iterator</strong>:<br>
An input iterator returned by <em>begin</em> and <em>end</em> (see
below)
<li> <strong>const_reverse_iterator</strong>:<br>
An reverse input iterator returned by the members <em>rbegin</em> and
<em>rend</em> (see below)
</ul>
<li> <strong>const_hdr_iterator</strong>:<br>
An input iterator returned by the members <em>beginh</em> and <em>endh</em> (see
below)
<li> <strong>const_reverse_hdr_iterator</strong>:<br>
An reverse input iterator returned by the members <em>rbeginh</em> and
<em>rendh</em> (see below)
)
Objects of these two iterator types point to header lines. Their
derefenced type is <em>std::string</em>.
<p>
<h2>CONSTRUCTORS</h2>
<ul>
<li> <strong>MailHeaders(std::istream &in, Mode mode = READ)</strong>:<br>
This constructor defines the file containing the e-mail to be
processed. The second parameter is by default <strong>MailHeaders::READ</strong>, causing
the object to start reading the e-mail immediately. If set to
<strong>MailHeaders::DONT_READ</strong>, the e-mail is not read. In that case the member
<em>read</em> can be called to process the e-mail later.
</ul>
The copy and move constructors are available.
<p>
<h2>OVERLOADED OPERATORS</h2>
<p>
<ul>
<li> <strong>std::string const &operator[](size_t idx) const</strong>:<br>
Returns the <em>idx</em>-th header line
</ul>
The move assignment operator is available
<p>
<h2>MEMBER FUNCTIONS</h2>
<p>
<ul>
<li> <strong>const_iterator begin() const</strong>:<br>
Returns an iterator to the first line of the mail headers.
<p>
<li> <strong>const_hdr_iterator beginh() const</strong>:<br>
Returns the begin-iterator corresponding to the first header selected by
the <em>setHeaderIterator</em> member.
<p>
<li> <strong>const_iterator end() const</strong>:<br>
Returns an iterator beyond the last line of the mail headers.
<p>
<li> <strong>const_hdr_iterator endh() const</strong>:<br>
Returns the end-iterator matching <em>beginh</em>. Note that the member
function's name ends in <em>h</em>, to distinguish it from the
<em>vector<string>::end</em> member.
<p>
<li> <strong>const_reverse_iterator rbegin() const</strong>:<br>
Returns an iterator to the last line of the mail headers.
<p>
<li> <strong>const_reverse_hdr_iterator rbeginh() const</strong>:<br>
Returns the reversed begin-iterator corresponding to the last header
selected by the <em>setHeaderIterator</em> member.
<p>
<li> <strong>void read()</strong>:<br>
Reads the mail-headers from the file passed to the <strong>FBB::MailHeaders</strong>
object's constructor. An <strong>FBB::Errno</strong> object is thrown if the mailheaders
were already read or if the file is incomplete (i.e., the (obligatory) blank
line wasn't found).
<p>
<li> <strong>const_iterator rend() const</strong>:<br>
Returns an iterator before the first line of the mail headers.
<p>
<li> <strong>const_reverse_hdr_iterator rendh() const</strong>:<br>
Returns the reversed end-iterator matching <em>rbeginh</em>.
<p>
<li> <strong>void setHeaderIterator(char const *header, Match match = FULL)</strong>:<br>
Sets the header-iterators to the specified <em>header</em>. The parameter
<em>match</em> defines the match-type to use when selecting headers. The default
<strong>FBB::MailHeaders::FULL</strong>, indicates that the text provided in
<em>header</em> must match exactly an e-mail header. <br>
When matching headers the
colon terminating the header is <em>not</em> considered and should therefore
<em>not</em> be specified by <em>setHeaderIterator</em>. <br>
Alternative matching strategies are used when other values of
the enumeration <strong>FBB::Match</strong> are specified.<br>
The member <em>setHeaderIterator</em> <em>must</em> have been called at least once
or the members <em>beginh</em> and <em>rendh</em> will throw an <strong>FBB::Errno</strong>
exception. An <strong>FBB::Errno</strong> exception is also thrown if
<em>setHeaderIterator</em> is called when no mail headers are available.
<p>
<li> <strong>size_t size() const</strong>:<br>
Returns the number of header lines
</ul>
<p>
<h2>EXAMPLE</h2>
The following example shows the normal use of these members:
<pre>
// create a MailHeader object
MailHeaders mh(cin, MailHeaders::DONT_READ);
try
{ // read the headers
mh.read();
}
catch (Errno &err)
{
cout << err.what() << endl;
}
cout << "There are " << mh.size() << " header lines\n";
// look for the Received: headers
mh.setHeaderIterator("Received");
// show the Received headers
copy(mh.beginh(), mh.endh(),
ostream_iterator<std::string const>(cout, "\n"));
</pre>
<p>
<h2>FILES</h2>
<em>bobcat/mailheaders</em> - defines the class interface
<p>
<h2>SEE ALSO</h2>
<strong>bobcat</strong>(7)
<p>
<h2>BUGS</h2>
None Reported.
<p>
<h2>DISTRIBUTION FILES</h2>
<ul>
<li> <em>bobcat_2.20.01-x.dsc</em>: detached signature;
<li> <em>bobcat_2.20.01-x.tar.gz</em>: source archive;
<li> <em>bobcat_2.20.01-x_i386.changes</em>: change log;
<li> <em>libbobcat1_2.20.01-x_*.deb</em>: debian package holding the
libraries;
<li> <em>libbobcat1-dev_2.20.01-x_*.deb</em>: debian package holding the
libraries, headers and manual pages;
<li> <em>http://sourceforge.net/projects/bobcat</em>: public archive location;
</ul>
<p>
<h2>BOBCAT</h2>
Bobcat is an acronym of `Brokken's Own Base Classes And Templates'.
<p>
<h2>COPYRIGHT</h2>
This is free software, distributed under the terms of the
GNU General Public License (GPL).
<p>
<h2>AUTHOR</h2>
Frank B. Brokken (<strong>f.b.brokken@rug.nl</strong>).
<p>
|