| 164 | } |
| 165 | |
| 166 | void takeOwnership(GenericMap& from) |
| 167 | { |
| 168 | fb_assert(this != &from); |
| 169 | |
| 170 | clear(); |
| 171 | |
| 172 | tree = from.tree; |
| 173 | mCount = from.mCount; |
| 174 | |
| 175 | TreeAccessor treeAccessor(&from.tree); |
| 176 | |
| 177 | if (treeAccessor.getFirst()) |
| 178 | { |
| 179 | while (true) |
| 180 | { |
| 181 | bool haveMore = treeAccessor.fastRemove(); |
| 182 | if (!haveMore) |
| 183 | break; |
| 184 | } |
| 185 | } |
| 186 | |
| 187 | from.mCount = 0; |
| 188 | } |
| 189 | |
| 190 | // Clear the map |
| 191 | void clear() |
nothing calls this directly
no test coverage detected