for cVariable in CFile.Variables:
occCtr=0
for cVar2 in CFile.Variables:
if cVariable.Name == cVar2.Name:
occCtr+=1
if occCtr > 1:
res = False
errmsg += cVariab
我想寫入存儲在一個向量中的數據到文件中。因此,我使用以下例程: bool Grid::saveToFile() {
stringstream sstream;
for (size_t i = 0; i < taglist.size(); ++i)
{
if (i != 0)
sstream << ",";
sstream << t