kpilot
CUDCounter Class Reference
#include <cudcounter.h>
Detailed Description
Create-Update-Delete tracking of the plugin, used for reporting purposes (in a consistent manner).The intent is that this class is used by the conduit as it is syncing data. For this to be useful (and be used properly), the conduit needs to tell us how many creates, updates, and deletes it has made to a data store (PC or HH). It also needs to tell us how many records it started with and how many records it has at the conclusion of its processing. Using this information, we can report on it consistently as well as analyze the activity taken by the conduit and offer rollback functionality if we think the conduit has behaved improperly.
Definition at line 47 of file cudcounter.h.
Public Member Functions | |
| unsigned int | countCreated () const |
| unsigned int | countDeleted () const |
| unsigned int | countEnd () const |
| unsigned int | countStart () const |
| unsigned int | countUpdated () const |
| void | created (unsigned int c=1) |
| CUDCounter () | |
| void | deleted (unsigned int d=1) |
| QString | moo () const |
| unsigned int | percentCreated () const |
| unsigned int | percentDeleted () const |
| unsigned int | percentUpdated () const |
| void | setEndCount (unsigned int t) |
| void | setStartCount (unsigned int t) |
| void | updated (unsigned int u=1) |
| int | volatilityCount () const |
| int | volatilityPercent () const |
Constructor & Destructor Documentation
| CUDCounter::CUDCounter | ( | ) |
Definition at line 32 of file cudcounter.cc.
Member Function Documentation
| unsigned int CUDCounter::countCreated | ( | ) | const [inline] |
Definition at line 66 of file cudcounter.h.
| unsigned int CUDCounter::countDeleted | ( | ) | const [inline] |
Definition at line 68 of file cudcounter.h.
| unsigned int CUDCounter::countEnd | ( | ) | const [inline] |
Definition at line 70 of file cudcounter.h.
| unsigned int CUDCounter::countStart | ( | ) | const [inline] |
Definition at line 69 of file cudcounter.h.
| unsigned int CUDCounter::countUpdated | ( | ) | const [inline] |
Definition at line 67 of file cudcounter.h.
| void CUDCounter::created | ( | unsigned int | c = 1 |
) |
| void CUDCounter::deleted | ( | unsigned int | d = 1 |
) |
| QString CUDCounter::moo | ( | ) | const |
Measurement Of Objects -- report numbers of objects created, updated, deleted.
This string is already i18n()ed.
Definition at line 76 of file cudcounter.cc.
| unsigned int CUDCounter::percentCreated | ( | ) | const [inline] |
percentage of changes.
unfortunately, we have to rely on our developers (hi, self!) to correctly set total number of records conduits start with, so add a little protection...
Definition at line 87 of file cudcounter.h.
| unsigned int CUDCounter::percentDeleted | ( | ) | const [inline] |
Definition at line 89 of file cudcounter.h.
| unsigned int CUDCounter::percentUpdated | ( | ) | const [inline] |
Definition at line 88 of file cudcounter.h.
| void CUDCounter::setEndCount | ( | unsigned int | t | ) |
| void CUDCounter::setStartCount | ( | unsigned int | t | ) |
| void CUDCounter::updated | ( | unsigned int | u = 1 |
) |
| int CUDCounter::volatilityCount | ( | ) | const |
Returns the sum of created records, updated records and deleted records.
Definition at line 66 of file cudcounter.cc.
| int CUDCounter::volatilityPercent | ( | ) | const |
Returns 100 if startcount is 0 otherwhise volatilityCount() / startCount.
Definition at line 71 of file cudcounter.cc.
The documentation for this class was generated from the following files:
KDE 4.2 API Reference