QMap<int, QString> intToStr; intToStr[1] = "test" for (auto iter = intToStr.begin(); iter != intToStr.end(); ++iter) { //int aa = *iter; QString two = iter.value(); QString test = *iter;//对迭代器解引用是返回value值,按我的理解迭代器应该指向的是那一对数据啊 }
QMap<int, QString> intToStr; intToStr[1] = "test" for (auto iter = intToStr.begin(); iter != intToStr.end(); ++iter) { //int aa = *iter; QString two = iter.value(); QString test = *iter;//对迭代器解引用是返回value值,按我的理解迭代器应该指向的是那一对数据啊 }