- Timestamp:
- Apr 10, 2008, 5:35:20 PM (17 years ago)
- Location:
- code/branches/core2/src/orxonox/core
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core2/src/orxonox/core/ConfigFileManager.cc
r1020 r1023 111 111 std::list<ConfigFileEntry*>::iterator ConfigFileSection::getEntryIterator(const std::string& name, const std::string& fallback) 112 112 { 113 std::cout << "a33333333333333333333333333\n";114 113 for (std::list<ConfigFileEntry*>::iterator it = this->entries_.begin(); it != this->entries_.end(); ++it) 115 114 if ((*it)->getName() == name) … … 123 122 std::list<ConfigFileEntry*>::iterator ConfigFileSection::getEntryIterator(const std::string& name, unsigned int index, const std::string& fallback) 124 123 { 125 std::cout << "b3333333333333333333333333\n";126 124 for (std::list<ConfigFileEntry*>::iterator it = this->entries_.begin(); it != this->entries_.end(); ++it) 127 125 if (((*it)->getName() == name) && ((*it)->getIndex() == index)) … … 197 195 if (isComment(line)) 198 196 { 199 std::cout << "1_7\n";200 197 // New comment 201 198 newsection->getEntries().insert(newsection->getEntries().end(), new ConfigFileEntryComment(removeTrailingWhitespaces(line))); … … 204 201 else 205 202 { 206 std::cout << "1_8\n";207 203 unsigned int pos1 = line.find('='); 208 204 209 205 if (pos1 != std::string::npos && pos1 > 0) 210 206 { 211 std::cout << "1_9\n";212 207 // New entry 213 208 unsigned int pos2 = line.find('['); … … 220 215 if (value.size() > 0 && value[0] == '"' && betweenQuotes != "" && betweenQuotes.size() > 0) 221 216 { 222 std::cout << "1_10\n";223 217 value = betweenQuotes; 224 218 if (line.size() > pos1 + 1 + betweenQuotes.size() + 2) … … 227 221 else 228 222 { 229 std::cout << "1_11\n";230 223 unsigned int pos4 = getCommentPosition(line); 231 std::cout << "a\n";232 std::cout << line << std::endl;233 std::cout << line.substr(pos1 + 1, pos4 - pos1 - 1) << std::endl;234 224 value = removeTrailingWhitespaces(line.substr(pos1 + 1, pos4 - pos1 - 1)); 235 std::cout << value << std::endl;236 std::cout << "b\n";237 225 if (pos4 != std::string::npos) 238 226 comment = removeTrailingWhitespaces(line.substr(pos4)); 239 std::cout << comment << std::endl;240 std::cout << "c\n";241 227 } 242 228 243 std::cout << "1_12\n";244 229 if (pos2 != std::string::npos && pos3 != std::string::npos && pos3 > pos2 + 1) 245 230 { 246 std::cout << "1_13\n";247 231 // There might be an array index 248 232 unsigned int index = 0; … … 251 235 // New array 252 236 newsection->getEntries().insert(newsection->getEntries().end(), new ConfigFileEntryArrayValue(getStripped(line.substr(0, pos2)), index, value, comment)); 253 std::cout << "1_14\n";254 237 continue; 255 238 } … … 258 241 // New value 259 242 newsection->getEntries().insert(newsection->getEntries().end(), new ConfigFileEntryValue(getStripped(line.substr(0, pos1)), value, comment)); 260 std::cout << "1_15\n";261 243 continue; 262 244 } … … 264 246 } 265 247 } 266 std::cout << "1_16\n";267 248 268 249 file.close(); … … 272 253 // Save the file in case something changed (like stripped whitespaces) 273 254 this->save(); 274 std::cout << "1_17\n";275 255 } 276 256 … … 312 292 ConfigFileSection* ConfigFile::getSection(const std::string& section) 313 293 { 314 std::cout << "22222222222222222222\n";315 294 for (std::list<ConfigFileSection*>::iterator it = this->sections_.begin(); it != this->sections_.end(); ++it) 316 295 if ((*it)->getName() == section) … … 433 412 ConfigFile* ConfigFileManager::getFile(ConfigFileType type) 434 413 { 435 std::cout << "111111111111111111\n";436 414 std::map<ConfigFileType, ConfigFile*>::iterator it = this->configFiles_.find(type); 437 415 if (it != this->configFiles_.end()) -
code/branches/core2/src/orxonox/core/ConfigFileManager.h
r1020 r1023 76 76 { 77 77 public: 78 inline ConfigFileEntryValue(const std::string& name, const std::string& value = "", const std::string& additionalComment = "") : name_(name), value_(value), additionalComment_(additionalComment), bString_(false) { std::cout << "************* " << value << std::endl;}78 inline ConfigFileEntryValue(const std::string& name, const std::string& value = "", const std::string& additionalComment = "") : name_(name), value_(value), additionalComment_(additionalComment), bString_(false) {} 79 79 inline virtual ~ConfigFileEntryValue() {} 80 80 -
code/branches/core2/src/orxonox/core/ConfigValueContainer.cc
r1020 r1023 53 53 this->varname_ = varname; 54 54 55 this->value_ = defvalue; 55 56 this->bAddedDescription_ = false; 56 57 … … 97 98 void ConfigValueContainer::update() 98 99 { 99 std::cout << "AAA1: " << this->value_ << std::endl;100 std::cout << " : " << ConfigFileManager::getSingleton()->getValue(this->type_, this->sectionname_, this->varname_, this->defvalueString_) << std::endl;101 100 this->value_.fromString(ConfigFileManager::getSingleton()->getValue(this->type_, this->sectionname_, this->varname_, this->defvalueString_)); 102 std::cout << "AAA2: " << this->value_ << std::endl;103 101 } 104 102 -
code/branches/core2/src/orxonox/core/DebugLevel.cc
r1020 r1023 95 95 96 96 // Return a constant value while we're creating the object 97 return 4;97 return 2; 98 98 } 99 99 } -
code/branches/core2/src/orxonox/core/Language.cc
r1020 r1023 108 108 109 109 // Read the translation file after the language was configured 110 std::cout << "asdfasdfkjsfkdjaslfkjsaflkjsdfkl\n";111 110 this->readTranslatedLanguageFile(); 112 111 }
Note: See TracChangeset
for help on using the changeset viewer.