static Mapping hashToBiMap(const Hash &hash) { Mapping biMap; Hash::const_iterator it = hash.constBegin(); const Hash::const_iterator end = hash.constEnd(); for ( ; it != end; ++it) biMap.insert(Mapping::value_type(it.key(), it.value())); return biMap; }
void KCTimeDict::save(QDataStream &str) const { Hash::const_iterator it = m_hash.constBegin(); const Hash::const_iterator end = m_hash.constEnd(); for (; it != end; ++it) { str << it.key() << it.value(); } str << QString() << quint32(0); }
QStringList KCTimeDict::remainingResourceList() const { QSet<QString> resources; Hash::const_iterator it = m_hash.constBegin(); const Hash::const_iterator end = m_hash.constEnd(); for (; it != end; ++it) { const QString key = it.key(); const QString res = key.left(key.indexOf('|')); resources.insert(res); } return resources.toList(); }
void AncestorMoveMonitor::dump() { #ifndef QT_NO_DEBUG TRACE_CONTEXT(AncestorMoveMonitor::dump, EVideoInternal); for(Hash::const_iterator it = m_hash.begin(); it != m_hash.end(); ++it) { const QObject *ancestor = it.key(); TRACE("ancestor 0x%08x", ancestor); const TargetList& targetList = it.value(); VideoOutput* target = 0; foreach(target, targetList) { TRACE(" target 0x%08x", target); } }