CollectionStatistics Class Reference
from PyKDE4.akonadi import *
Namespace: Akonadi
Detailed Description
Provides statistics information of a Collection.
This class contains information such as total number of items, number of new and unread items, etc.
These information might be expensive to obtain and are thus not included when fetching collection with a CollectionFetchJob. They can be retrieved spearately using CollectionStatisticsJob.
Example:
Akonadi.Collection collection = ... Akonadi.CollectionStatisticsJob *job = new Akonadi.CollectionStatisticsJob( collection ); if ( job->exec() ) { Akonadi.CollectionStatistics statistics = job->statistics(); qDebug() << "Unread items:" << statistics.unreadCount(); }
This class is implicitely shared.
Methods | |
__init__ (self) | |
__init__ (self, Akonadi.CollectionStatistics other) | |
long | count (self) |
setCount (self, long count) | |
setUnreadCount (self, long count) | |
long | unreadCount (self) |
Method Documentation
__init__ | ( | self ) |
Creates a new collection statistics object.
__init__ | ( | self, | ||
Akonadi.CollectionStatistics | other | |||
) |
Creates a collection statistics object from an other one.
long count | ( | self ) |
Returns the number of items in this collection or -1 if this information is not available.
- See also:
- setCount()
- See also:
- unreadCount()
setCount | ( | self, | ||
long | count | |||
) |
Sets the number of items in this collection.
- Parameters:
-
count The number of items.
- See also:
- count()
setUnreadCount | ( | self, | ||
long | count | |||
) |
Sets the number of unread items in this collection.
- Parameters:
-
count The number of unread messages.
- See also:
- unreadCount()
long unreadCount | ( | self ) |
Returns the number of unread items in this collection or -1 if this information is not available.
- See also:
- setUnreadCount()
- See also:
- count()