Qt 4.8
Public Functions | Properties | List of all members
IapAddTimer Class Reference

Public Functions

void add (QString &iap_id, QIcdEngine *d)
 
void del (QString &iap_id)
 
 IapAddTimer ()
 
void removeAll ()
 
 ~IapAddTimer ()
 

Properties

QHash< QString, _IapAddTimer *> timers
 

Detailed Description

Definition at line 124 of file qicdengine.cpp.

Constructors and Destructors

◆ IapAddTimer()

IapAddTimer::IapAddTimer ( )
inline

Definition at line 128 of file qicdengine.cpp.

128 {}

◆ ~IapAddTimer()

IapAddTimer::~IapAddTimer ( )
inline

Definition at line 129 of file qicdengine.cpp.

129 {}

Functions

◆ add()

void IapAddTimer::add ( QString iap_id,
QIcdEngine d 
)

Definition at line 149 of file qicdengine.cpp.

150 {
151  if (timers.contains(iap_id)) {
152  _IapAddTimer *iap = timers.value(iap_id);
153  iap->add(iap_id, d);
154  } else {
155  _IapAddTimer *iap = new _IapAddTimer;
156  iap->add(iap_id, d);
157  timers.insert(iap_id, iap);
158  }
159 }
void add(QString &iap_id, QIcdEngine *d)
Definition: qicdengine.cpp:103
bool contains(const Key &key) const
Returns true if the hash contains an item with the key; otherwise returns false.
Definition: qhash.h:872
const T value(const Key &key) const
Returns the value associated with the key.
Definition: qhash.h:606
iterator insert(const Key &key, const T &value)
Inserts a new item with the key and a value of value.
Definition: qhash.h:753
QHash< QString, _IapAddTimer *> timers
Definition: qicdengine.cpp:125

◆ del()

void IapAddTimer::del ( QString iap_id)

Definition at line 161 of file qicdengine.cpp.

162 {
163  if (timers.contains(iap_id)) {
164  _IapAddTimer *iap = timers.take(iap_id);
165  delete iap;
166  }
167 }
T take(const Key &key)
Removes the item with the key from the hash and returns the value associated with it...
Definition: qhash.h:807
bool contains(const Key &key) const
Returns true if the hash contains an item with the key; otherwise returns false.
Definition: qhash.h:872
QHash< QString, _IapAddTimer *> timers
Definition: qicdengine.cpp:125

◆ removeAll()

void IapAddTimer::removeAll ( )

Definition at line 137 of file qicdengine.cpp.

138 {
139  QHashIterator<QString, _IapAddTimer* > i(timers);
140  while (i.hasNext()) {
141  i.next();
142  _IapAddTimer *t = i.value();
143  delete t;
144  }
145  timers.clear();
146 }
void clear()
Removes all items from the hash.
Definition: qhash.h:574
QHash< QString, _IapAddTimer *> timers
Definition: qicdengine.cpp:125

Properties

◆ timers

QHash<QString, _IapAddTimer* > IapAddTimer::timers
private

Definition at line 125 of file qicdengine.cpp.


The documentation for this class was generated from the following file: