* Pushes the noed on top of the stack, changes currentIndex, and goes as deep as necessary for iteration. * */
| 405 | * Pushes the noed on top of the stack, changes currentIndex, and goes as deep as necessary for iteration. |
| 406 | * */ |
| 407 | void startAtNode(const SetNodeData* node) |
| 408 | { |
| 409 | Q_ASSERT(node->start() != node->end()); |
| 410 | currentIndex = node->start(); |
| 411 | |
| 412 | do { |
| 413 | nodeStack[nodeStackSize++] = node; |
| 414 | |
| 415 | if (nodeStackSize >= nodeStackAlloc) |
| 416 | resizeNodeStack(); |
| 417 | |
| 418 | if (node->contiguous()) |
| 419 | break; //We need no finer granularity, because the range is contiguous |
| 420 | node = Set::Iterator::getDataRepository(repository).itemFromIndex(node->leftNode()); |
| 421 | } while (node); |
| 422 | Q_ASSERT(currentIndex >= nodeStack[0]->start()); |
| 423 | } |
| 424 | }; |
| 425 | |
| 426 | std::set<Index> Set::stdSet() const |
no test coverage detected