| 1283 | } |
| 1284 | |
| 1285 | void Config::setMajorVersion(unsigned int version) |
| 1286 | { |
| 1287 | if (version < FirstSupportedMajorVersion |
| 1288 | || version > LastSupportedMajorVersion) |
| 1289 | { |
| 1290 | std::ostringstream os; |
| 1291 | os << "The version is " << version |
| 1292 | << " where supported versions start at " |
| 1293 | << FirstSupportedMajorVersion |
| 1294 | << " and end at " |
| 1295 | << LastSupportedMajorVersion |
| 1296 | << "."; |
| 1297 | throw Exception(os.str().c_str()); |
| 1298 | } |
| 1299 | m_impl->m_majorVersion = version; |
| 1300 | m_impl->m_minorVersion = LastSupportedMinorVersion[version - 1]; |
| 1301 | |
| 1302 | AutoMutex lock(getImpl()->m_cacheidMutex); |
| 1303 | getImpl()->resetCacheIDs(); |
| 1304 | } |
| 1305 | |
| 1306 | unsigned Config::getMinorVersion() const |
| 1307 | { |