Main Page Class Hierarchy Alphabetical List Compound List Examples

messageid.h
1/***************************************************************************
2 copyright : (C) 2002-2008 by Stefano Barbato
3 email : stefano@codesink.org
4
5 $Id: messageid.h,v 1.15 2008-10-07 11:06:27 tat Exp $
6 ***************************************************************************/
7#ifndef _MIMETIC_MESSAGEID_H_
8#define _MIMETIC_MESSAGEID_H_
9#ifdef HAVE_STDINT_H
10#include <stdint.h>
11#endif
12#include <string>
13#include <mimetic/libconfig.h>
14#ifdef HAVE_INTTYPES_H
15#include <inttypes.h>
16#endif
17#include <mimetic/utils.h>
18#include <mimetic/os/utils.h>
19#include <mimetic/rfc822/fieldvalue.h>
20
21 namespace mimetic
22{
23
24
25/// Message-ID field value
26/// On Win32 Winsock library must be initialized before using this class.
27 struct MessageId: public FieldValue
28{
29 MessageId(uint32_t thread_id = 0 );
30 MessageId(const std::string&);
31 std::string str() const;
32 void set(const std::string&);
33 protected:
34 FieldValue* clone() const;
35 private:
36 static unsigned int ms_sequence_number;
37 std::string m_msgid;
38};
39
40
41}
42
43#endif
mimetic
Definition body.h:18