• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdepim
  • Sitemap
  • Contact Us
 

kmail

kmmsgbase.cpp File Reference

#include <config-kmail.h>
#include "kmmsgbase.h"
#include "globalsettings.h"
#include "kmfolderindex.h"
#include "kmfolder.h"
#include "kmheaders.h"
#include "kmmsgdict.h"
#include "kmmessagetag.h"
#include "messageproperty.h"
#include <QByteArray>
#include <kdebug.h>
#include <kde_file.h>
#include <kglobal.h>
#include <kcharsets.h>
#include <kascii.h>
#include <kcodecs.h>
#include <kdatetime.h>
#include <kconfiggroup.h>
#include <mimelib/mimepp.h>
#include <kmime/kmime_codecs.h>
#include <kmime/kmime_util.h>
#include <QTextCodec>
#include <QRegExp>
#include <ctype.h>
#include <stdlib.h>
#include <unistd.h>

Include dependency graph for kmmsgbase.cpp:

Go to the source code of this file.


Defines

#define kmail_swap_16(x)   ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8))
#define kmail_swap_32(x)
#define kmail_swap_64(x)
#define memcpy_networkorder(to, from, len)   swab((char *)(from), (char *)(to), len)
#define STORE_DATA(type, x)   STORE_DATA_LEN(type, &x, sizeof(x), false)
#define STORE_DATA_LEN(type, x, len, network_order)

Functions

template<typename T>
void copy_from_stream (T &x)
QByteArray fallbackCharsetForRFC2047Decoding (const QByteArray &prefCharset)
static void swapEndian (QString &str)

Variables

static const QByteArray especials = "()<>@,;:\"/[]?.= \033"
static uchar * g_chunk = 0
static int g_chunk_length = 0
static int g_chunk_offset = 0
static QStringList sForwardSubjPrefixes
static bool sReplaceForwSubjPrefix
static bool sReplaceSubjPrefix
static QStringList sReplySubjPrefixes

Define Documentation

#define kmail_swap_16 ( x   )     ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8))

Definition at line 48 of file kmmsgbase.cpp.

#define kmail_swap_32 ( x   ) 

Value:

((((x) & 0xff000000) >> 24) | (((x) & 0x00ff0000) >>  8) |            \
      (((x) & 0x0000ff00) <<  8) | (((x) & 0x000000ff) << 24))

Definition at line 56 of file kmmsgbase.cpp.

#define kmail_swap_64 ( x   ) 

Value:

((((x) & 0xff00000000000000ull) >> 56)                    \
      | (((x) & 0x00ff000000000000ull) >> 40)                     \
      | (((x) & 0x0000ff0000000000ull) >> 24)                     \
      | (((x) & 0x000000ff00000000ull) >> 8)                      \
      | (((x) & 0x00000000ff000000ull) << 8)                      \
      | (((x) & 0x0000000000ff0000ull) << 24)                     \
      | (((x) & 0x000000000000ff00ull) << 40)                     \
      | (((x) & 0x00000000000000ffull) << 56))

Definition at line 65 of file kmmsgbase.cpp.

#define memcpy_networkorder ( to,
from,
len   )     swab((char *)(from), (char *)(to), len)

Definition at line 1024 of file kmmsgbase.cpp.

#define STORE_DATA ( type,
x   )     STORE_DATA_LEN(type, &x, sizeof(x), false)

Definition at line 1043 of file kmmsgbase.cpp.

#define STORE_DATA_LEN ( type,
x,
len,
network_order   ) 

Value:

do { \
    int len2 = (len > 256) ? 256 : len; \
    if(csize < (length + (len2 + sizeof(short) + sizeof(MsgPartType)))) \
      ret = (uchar *)realloc(ret, csize += len2+sizeof(short)+sizeof(MsgPartType)); \
    quint32 t = (quint32) type; memcpy(ret+length, &t, sizeof(t)); \
    quint16 l = len2; memcpy(ret+length+sizeof(t), &l, sizeof(l)); \
    if (network_order) \
       memcpy_networkorder(ret+length+sizeof(t)+sizeof(l), x, len2); \
    else \
       memcpy(ret+length+sizeof(t)+sizeof(l), x, len2); \
    length += len2+sizeof(t)+sizeof(l); \
  } while(0)

Definition at line 1029 of file kmmsgbase.cpp.


Function Documentation

template<typename T>
void @233::copy_from_stream ( T &  x  )  [inline, static]

Definition at line 796 of file kmmsgbase.cpp.

QByteArray fallbackCharsetForRFC2047Decoding ( const QByteArray &  prefCharset  ) 

Definition at line 403 of file kmmsgbase.cpp.

static void swapEndian ( QString &  str  )  [static]

Definition at line 782 of file kmmsgbase.cpp.


Variable Documentation

const QByteArray especials = "()<>@,;:\"/[]?.= \033" [static]

Definition at line 443 of file kmmsgbase.cpp.

uchar* g_chunk = 0 [static]

Definition at line 793 of file kmmsgbase.cpp.

int g_chunk_length = 0 [static]

Definition at line 792 of file kmmsgbase.cpp.

int g_chunk_offset = 0 [static]

Definition at line 792 of file kmmsgbase.cpp.

QStringList sForwardSubjPrefixes [static]

Definition at line 1128 of file kmmsgbase.cpp.

bool sReplaceForwSubjPrefix [static]

Definition at line 1129 of file kmmsgbase.cpp.

bool sReplaceSubjPrefix [static]

Definition at line 1129 of file kmmsgbase.cpp.

QStringList sReplySubjPrefixes [static]

Definition at line 1128 of file kmmsgbase.cpp.

kmail

Skip menu "kmail"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdepim

Skip menu "kdepim"
  • akonadi
  •   clients
  •   kabc
  •   kcal
  •   kcm
  • akregator
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt
  • kdgantt1
  • kjots
  • kleopatra
  • kmail
  • kmobiletools
  • knode
  • knotes
  • kontact
  • kontactinterfaces
  • korganizer
  •   korgac
  • kpilot
  • ktimetracker
  •   doc
  • libkdepim
  • libkholidays
  • libkleo
  • libkpgp
  • maildir
Generated for kdepim by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal