mailcommon
Go to the documentation of this file.
20 #ifndef MAILCOMMON_MAILFILTER_H
21 #define MAILCOMMON_MAILFILTER_H
23 #include "../mailcommon_export.h"
26 #include "../search/searchpattern.h"
28 #include <kshortcut.h>
29 #include <akonadi/collection.h>
31 #include <kmime/kmime_message.h>
33 #include <QtCore/QDataStream>
37 namespace MailCommon {
78 explicit MailFilter(
const KConfigGroup & aConfig,
bool internal,
bool & needUpdate );
89 QString identifier()
const;
105 ReturnCode execActions(
ItemContext &
context,
bool& stopIt ,
bool applyOnOutbound)
const ;
113 void writeConfig( KConfigGroup& config,
bool exportFilter )
const;
116 bool readConfig(
const KConfigGroup& config,
bool interactive =
false );
122 bool isEmpty()
const;
146 void setApplyOnOutbound(
bool aApply =
true );
152 void setApplyBeforeOutbound(
bool aApply =
true );
158 bool applyOnOutbound()
const;
164 bool applyBeforeOutbound()
const;
170 void setApplyOnInbound(
bool aApply =
true );
176 bool applyOnInbound()
const;
182 void setApplyOnExplicit(
bool aApply =
true );
188 bool applyOnExplicit()
const;
197 void setApplicability( AccountType aApply = All );
205 AccountType applicability()
const;
213 void setApplyOnAccount(
const QString&
id,
bool aApply =
true );
219 bool applyOnAccount(
const QString&
id )
const;
221 void setStopProcessingHere(
bool aStop );
222 bool stopProcessingHere()
const;
226 void setConfigureShortcut(
bool aShort );
232 bool configureShortcut()
const;
238 void setConfigureToolbar(
bool aTool );
244 bool configureToolbar()
const;
249 QString toolbarName()
const;
258 void setToolbarName(
const QString &toolbarName );
264 void setShortcut(
const KShortcut &shortcut );
269 const KShortcut & shortcut()
const;
275 void setIcon(
const QString &icon );
280 QString icon()
const;
289 bool folderRemoved(
const Akonadi::Collection& aFolder,
const Akonadi::Collection& aNewFolder );
295 const QString asString()
const;
302 void setAutoNaming(
bool useAutomaticNames );
306 bool isAutoNaming()
const;
310 bool isEnabled()
const;
311 void setEnabled(
bool );
313 void generateSieveScript(QStringList &requires, QString &code);
319 QStringList mAccounts;
321 QString mToolbarName;
323 bool bApplyOnInbound : 1;
324 bool bApplyBeforeOutbound : 1;
325 bool bApplyOnOutbound : 1;
326 bool bApplyOnExplicit : 1;
327 bool bStopProcessingHere : 1;
328 bool bConfigureShortcut : 1;
329 bool bConfigureToolbar : 1;
330 bool bAutoNaming : 1;
332 AccountType mApplicability;
ReturnCode
Result codes returned by process.
const int FILTER_MAX_ACTIONS
This class is an abstraction of a search over messages.
#define MAILCOMMON_EXPORT
AccountType
Account type codes used by setApplicability.
MAILCOMMON_EXPORT QDataStream & operator>>(QDataStream &stream, MailFilter &filter)
MAILCOMMON_EXPORT QDataStream & operator<<(QDataStream &stream, const MailFilter &filter)
A helper class for the filtering process.
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:15 by
doxygen 1.8.7 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.