Get value for key, returns nullptr if not found
| 84 | |
| 85 | // Get value for key, returns nullptr if not found |
| 86 | T *find_value(const Key &key) { |
| 87 | ValueWithTimestamp *vwt = mMap.find_value(key); |
| 88 | if (vwt) { |
| 89 | // Update access time |
| 90 | auto curr = mCurrentTime++; |
| 91 | vwt->last_access_time = curr; |
| 92 | return &vwt->value; |
| 93 | } |
| 94 | return nullptr; |
| 95 | } |
| 96 | |
| 97 | // Get value for key, returns nullptr if not found (const version) |
| 98 | const T *find_value(const Key &key) const { |
no outgoing calls
no test coverage detected