| 298 | } |
| 299 | |
| 300 | int FileContents::lookup(char *key) |
| 301 | { |
| 302 | if (indexField == -1) { |
| 303 | ERROR("Invalid Index File: %s", fileName); |
| 304 | } |
| 305 | if (!indexMap) { |
| 306 | ERROR("Invalid Index File: %s", fileName); |
| 307 | } |
| 308 | |
| 309 | str_int_map::iterator index_it = indexMap->find(key); |
| 310 | if (index_it == indexMap->end()) { |
| 311 | return -1; |
| 312 | } |
| 313 | return index_it->second; |
| 314 | } |
| 315 | |
| 316 | |
| 317 | void FileContents::insert(char *value) |
no test coverage detected