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

mailcommon

  • MailCommon
  • FilterLog
Public Types | Signals | Public Member Functions | Static Public Member Functions | List of all members
MailCommon::FilterLog Class Reference

#include <filterlog.h>

Inheritance diagram for MailCommon::FilterLog:
Inheritance graph
[legend]

Public Types

enum  ContentType {
  Meta = 1, PatternDescription = 2, RuleResult = 4, PatternResult = 8,
  AppliedAction = 16
}
 

Signals

void logEntryAdded (const QString &entry)
 
void logShrinked ()
 
void logStateChanged ()
 

Public Member Functions

virtual ~FilterLog ()
 
void add (const QString &entry, ContentType type)
 
void addSeparator ()
 
void clear ()
 
void dump ()
 
bool isContentTypeEnabled (ContentType type) const
 
bool isLogging () const
 
QStringList logEntries () const
 
long maxLogSize () const
 
bool saveToFile (const QString &fileName) const
 
void setContentTypeEnabled (ContentType type, bool enabled)
 
void setLogging (bool active)
 
void setMaxLogSize (long size=-1)
 
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
 
 QObject (QObject *parent, const char *name)
 
virtual  ~QObject ()
 
bool blockSignals (bool block)
 
QObject * child (const char *objName, const char *inheritsClass, bool recursiveSearch) const
 
const QObjectList & children () const
 
const char * className () const
 
bool connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const
 
void deleteLater ()
 
void destroyed (QObject *obj)
 
bool disconnect (const QObject *receiver, const char *method)
 
bool disconnect (const char *signal, const QObject *receiver, const char *method)
 
void dumpObjectInfo ()
 
void dumpObjectTree ()
 
QList< QByteArray > dynamicPropertyNames () const
 
virtual bool event (QEvent *e)
 
virtual bool eventFilter (QObject *watched, QEvent *event)
 
T findChild (const QString &name) const
 
QList< T > findChildren (const QRegExp &regExp) const
 
QList< T > findChildren (const QString &name) const
 
bool inherits (const char *className) const
 
void insertChild (QObject *object)
 
void installEventFilter (QObject *filterObj)
 
bool isA (const char *className) const
 
bool isWidgetType () const
 
void killTimer (int id)
 
virtual const QMetaObject * metaObject () const
 
void moveToThread (QThread *targetThread)
 
const char * name () const
 
const char * name (const char *defaultName) const
 
QString objectName () const
 
QObject * parent () const
 
QVariant property (const char *name) const
 
void removeChild (QObject *object)
 
void removeEventFilter (QObject *obj)
 
void setName (const char *name)
 
void setObjectName (const QString &name)
 
void setParent (QObject *parent)
 
bool setProperty (const char *name, const QVariant &value)
 
bool signalsBlocked () const
 
int startTimer (int interval)
 
QThread * thread () const
 

Static Public Member Functions

static FilterLog * instance ()
 
static QString recode (const QString &plain)
 
- Static Public Member Functions inherited from QObject
bool connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
 
bool connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
 
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
 
QString tr (const char *sourceText, const char *disambiguation, int n)
 
QString trUtf8 (const char *sourceText, const char *disambiguation, int n)
 

Additional Inherited Members

- Protected Member Functions inherited from QObject
bool checkConnectArgs (const char *signal, const QObject *object, const char *method)
 
virtual void childEvent (QChildEvent *event)
 
virtual void connectNotify (const char *signal)
 
virtual void customEvent (QEvent *event)
 
virtual void disconnectNotify (const char *signal)
 
int receivers (const char *signal) const
 
QObject * sender () const
 
int senderSignalIndex () const
 
virtual void timerEvent (QTimerEvent *event)
 
- Static Protected Member Functions inherited from QObject
QByteArray normalizeSignalSlot (const char *signalSlot)
 
- Properties inherited from QObject
 objectName
 

Detailed Description

KMail Filter Log Collector.

The filter log helps to collect log information about the filter process in KMail. It's implemented as singleton, so it's easy to direct pieces of information to a unique instance. It's possible to activate / deactivate logging. All collected log information can get thrown away, the next added log entry is the first one until another clearing. A signal is emitted whenever a new logentry is added, when the log was cleared or any log state was changed.

Author
Andreas Gungl a.gun.nosp@m.gl@g.nosp@m.mx.de

Definition at line 55 of file filterlog.h.

Member Enumeration Documentation

enum MailCommon::FilterLog::ContentType

Describes the type of content that will be logged.

Enumerator
Meta 

Log all meta data.

PatternDescription 

Log all pattern description.

RuleResult 

Log all rule matching results.

PatternResult 

Log all pattern matching results.

AppliedAction 

Log all applied actions.

Definition at line 73 of file filterlog.h.

Constructor & Destructor Documentation

FilterLog::~FilterLog ( )
virtual

Destroys the filter log.

Definition at line 102 of file filterlog.cpp.

Member Function Documentation

void FilterLog::add ( const QString &  entry,
ContentType  type 
)

Adds the given log entry under the given content type to the log.

Definition at line 164 of file filterlog.cpp.

void FilterLog::addSeparator ( )

Adds a separator line to the log.

Definition at line 181 of file filterlog.cpp.

void FilterLog::clear ( )

Clears the log.

Definition at line 186 of file filterlog.cpp.

void FilterLog::dump ( )

Dumps the log to console.

Used for debugging.

Definition at line 197 of file filterlog.cpp.

FilterLog * FilterLog::instance ( )
static

Returns the single global instance of the filter log.

Definition at line 107 of file filterlog.cpp.

bool FilterLog::isContentTypeEnabled ( ContentType  type) const

Returns whether the given content type is enabled for logging.

Definition at line 159 of file filterlog.cpp.

bool FilterLog::isLogging ( ) const

Returns whether the filter log is currently active.

Definition at line 116 of file filterlog.cpp.

QStringList FilterLog::logEntries ( ) const

Returns the list of log entries.

Definition at line 192 of file filterlog.cpp.

void MailCommon::FilterLog::logEntryAdded ( const QString &  entry)
signal

This signal is emitted whenever a new entry has been added to the log.

void MailCommon::FilterLog::logShrinked ( )
signal

This signal is emitted whenever the log has shrinked.

void MailCommon::FilterLog::logStateChanged ( )
signal

This signal is emitted whenever the activity of the filter log has been changed.

long FilterLog::maxLogSize ( ) const

Returns the maximum size of the log in bytes.

Definition at line 143 of file filterlog.cpp.

QString FilterLog::recode ( const QString &  plain)
static

Returns an escaped version of the log which can be used in a HTML document.

Definition at line 228 of file filterlog.cpp.

bool FilterLog::saveToFile ( const QString &  fileName) const

Saves the log to the file with the given fileName.

Returns
true on success or false on failure.

Definition at line 208 of file filterlog.cpp.

void FilterLog::setContentTypeEnabled ( ContentType  type,
bool  enabled 
)

Sets whether a given content type will be enabled for logging.

Definition at line 148 of file filterlog.cpp.

void FilterLog::setLogging ( bool  active)

Sets whether the filter log is currently active.

Definition at line 121 of file filterlog.cpp.

void FilterLog::setMaxLogSize ( long  size = -1)

Sets the maximum size of the log in bytes.

Definition at line 127 of file filterlog.cpp.


The documentation for this class was generated from the following files:
  • filterlog.h
  • filterlog.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:31:41 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

mailcommon

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

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer
  • pimprint

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal