| 193 | } |
| 194 | |
| 195 | void Context::setSearchPath(const char * path) |
| 196 | { |
| 197 | // TODO: Do nothing if the path is already present in the list of paths. The important aspect |
| 198 | // is to preserve the cache content. |
| 199 | |
| 200 | AutoMutex lock(getImpl()->m_resultsCacheMutex); |
| 201 | |
| 202 | getImpl()->m_searchPaths = StringUtils::Split(path ? path : "", ':'); |
| 203 | getImpl()->m_searchPath = (path ? path : ""); |
| 204 | getImpl()->clearCaches(); |
| 205 | } |
| 206 | |
| 207 | const char * Context::getSearchPath() const |
| 208 | { |