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

kmail

KMSearchRuleNumerical Class Reference

#include <kmsearchpattern.h>

Inheritance diagram for KMSearchRuleNumerical:

Inheritance graph
[legend]

List of all members.


Detailed Description

This class represents a search to be performed against a numerical value, such as the age of the message in days or its size.

This class represents a search pattern rule operating on numerical values.

Definition at line 207 of file kmsearchpattern.h.


Public Member Functions

virtual bool isEmpty () const
 KMSearchRuleNumerical (const QByteArray &field=0, Function function=FuncContains, const QString &contents=QString())
virtual bool matches (const KMMessage *msg) const
bool matchesInternal (long numericalValue, long numericalMsgContents, const QString &msgContents) const

Constructor & Destructor Documentation

KMSearchRuleNumerical::KMSearchRuleNumerical ( const QByteArray &  field = 0,
Function  function = FuncContains,
const QString &  contents = QString() 
) [explicit]

Definition at line 522 of file kmsearchpattern.cpp.


Member Function Documentation

bool KMSearchRuleNumerical::isEmpty (  )  const [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 528 of file kmsearchpattern.cpp.

bool KMSearchRuleNumerical::matches ( const KMMessage *  msg  )  const [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 537 of file kmsearchpattern.cpp.

bool KMSearchRuleNumerical::matchesInternal ( long  numericalValue,
long  numericalMsgContents,
const QString &  msgContents 
) const

Helper for the main matches() method.

Does the actual comparing.

Definition at line 566 of file kmsearchpattern.cpp.


The documentation for this class was generated from the following files:
  • kmsearchpattern.h
  • kmsearchpattern.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