#include <kmsearchpattern.h>
Public Member Functions | |
KMSearchRuleStatus (const TQCString &field=0, Function function=FuncContains, const TQString &contents=TQString()) | |
KMSearchRuleStatus (int status, Function function=FuncContains) | |
virtual bool | isEmpty () const |
virtual bool | matches (const KMMessage *msg) const |
virtual bool | matches (const DwString &, KMMessage &, const DwBoyerMoore *, int) const |
Public Member Functions inherited from KMSearchRule | |
KMSearchRule (const TQCString &field=0, Function=FuncContains, const TQString &contents=TQString()) | |
KMSearchRule (const KMSearchRule &other) | |
const KMSearchRule & | operator= (const KMSearchRule &other) |
virtual bool | requiresBody () const |
void | writeConfig (TDEConfig *config, int aIdx) const |
Function | function () const |
void | setFunction (Function aFunction) |
TQCString | field () const |
void | setField (const TQCString &field) |
TQString | contents () const |
void | setContents (const TQString &aContents) |
const TQString | asString () const |
Static Public Member Functions | |
static KMMsgStatus | statusFromEnglishName (const TQString &) |
Static Public Member Functions inherited from KMSearchRule | |
static KMSearchRule * | createInstance (const TQCString &field=0, Function function=FuncContains, const TQString &contents=TQString()) |
static KMSearchRule * | createInstance (const TQCString &field, const char *function, const TQString &contents) |
static KMSearchRule * | createInstance (const KMSearchRule &other) |
static KMSearchRule * | createInstanceFromConfig (const TDEConfig *config, int aIdx) |
Additional Inherited Members | |
Public Types inherited from KMSearchRule | |
enum | Function { FuncNone = -1 , FuncContains =0 , FuncContainsNot , FuncEquals , FuncNotEqual , FuncRegExp , FuncNotRegExp , FuncIsGreater , FuncIsLessOrEqual , FuncIsLess , FuncIsGreaterOrEqual , FuncIsInAddressbook , FuncIsNotInAddressbook , FuncIsInCategory , FuncIsNotInCategory , FuncHasAttachment , FuncHasNoAttachment } |
Detailed Description
This class represents a search to be performed against the status of a messsage.
The status is represented by a bitfield.
This class represents a search pattern rule operating on message status.
Definition at line 269 of file kmsearchpattern.h.
Member Function Documentation
◆ isEmpty()
|
virtual |
Determine whether the rule is worth considering.
It isn't if either the field is not set or the contents is empty. KFilter should make sure that it's rule list contains only non-empty rules, as matches doesn't check this.
Implements KMSearchRule.
Definition at line 662 of file kmsearchpattern.cpp.
◆ matches() [1/2]
|
virtual |
Optimized version tries to match the rule against the given.
- See also
- DwString.
- Returns
- TRUE if the rule matched, FALSE otherwise.
Reimplemented from KMSearchRule.
Definition at line 667 of file kmsearchpattern.cpp.
◆ matches() [2/2]
|
virtual |
Tries to match the rule against the given KMMessage.
- Returns
- TRUE if the rule matched, FALSE otherwise. Must be implemented by subclasses.
Implements KMSearchRule.
Definition at line 674 of file kmsearchpattern.cpp.
The documentation for this class was generated from the following files: