KIMAP Library
21 #include "sessionlogger_p.h"
27 using namespace KIMAP;
29 SessionLogger::SessionLogger()
32 static qint64 nextId = 0;
35 m_file.setFileName( QLatin1String(qgetenv(
"KIMAP_LOGFILE" ))
36 + QLatin1Char(
'.') + QString::number( getpid() )
37 + QLatin1Char(
'.') + QString::number( m_id ) );
38 if (!m_file.open( QFile::WriteOnly )) {
39 kDebug()<<
" m_file can be open in write only";
43 SessionLogger::~SessionLogger()
48 void SessionLogger::dataSent(
const QByteArray &data )
50 m_file.write(
"C: "+data.trimmed()+
'\n' );
54 void SessionLogger::dataReceived(
const QByteArray &data )
56 m_file.write(
"S: "+data.trimmed()+
'\n' );
60 void SessionLogger::disconnectionOccured()
62 m_file.write(
"X\n" );
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:08 by
doxygen 1.8.7 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.