diff --git a/arangod/Indexes/EdgeIndex.cpp b/arangod/Indexes/EdgeIndex.cpp index f30ef34933..ab1fa59489 100644 --- a/arangod/Indexes/EdgeIndex.cpp +++ b/arangod/Indexes/EdgeIndex.cpp @@ -538,62 +538,6 @@ int EdgeIndex::batchInsert (std::vector const* documents, return TRI_ERROR_NO_ERROR; } -//////////////////////////////////////////////////////////////////////////////// -/// @brief looks up edges using the index, restarting at the edge pointed at -/// by next -//////////////////////////////////////////////////////////////////////////////// - -void EdgeIndex::lookup (TRI_edge_index_iterator_t const* edgeIndexIterator, - std::vector& result, - TRI_doc_mptr_copy_t*& next, - size_t batchSize) { - - auto callback = [&result] (TRI_doc_mptr_t* data) -> void { - result.emplace_back(*(data)); - }; - - std::vector* found = nullptr; - if (next == nullptr) { - if (edgeIndexIterator->_direction == TRI_EDGE_OUT) { - found = _edgesFrom->lookupByKey(&(edgeIndexIterator->_edge), batchSize); - } - else if (edgeIndexIterator->_direction == TRI_EDGE_IN) { - found = _edgesTo->lookupByKey(&(edgeIndexIterator->_edge), batchSize); - } - else { - TRI_ASSERT(false); - } - if (found != nullptr && found->size() != 0) { - next = static_cast(found->back()); - } - } - else { - if (edgeIndexIterator->_direction == TRI_EDGE_OUT) { - found = _edgesFrom->lookupByKeyContinue(next, batchSize); - } - else if (edgeIndexIterator->_direction == TRI_EDGE_IN) { - found = _edgesTo->lookupByKeyContinue(next, batchSize); - } - else { - TRI_ASSERT(false); - } - if (found != nullptr && found->size() != 0) { - next = static_cast(found->back()); - } - else { - next = nullptr; - } - } - - if (found != nullptr) { - for (auto& v : *found) { - callback(v); - } - - delete found; - } -} - //////////////////////////////////////////////////////////////////////////////// /// @brief provides a size hint for the edge index //////////////////////////////////////////////////////////////////////////////// diff --git a/arangod/Indexes/EdgeIndex.h b/arangod/Indexes/EdgeIndex.h index bd2f6dabff..d4fffbccd8 100644 --- a/arangod/Indexes/EdgeIndex.h +++ b/arangod/Indexes/EdgeIndex.h @@ -154,16 +154,6 @@ namespace triagens { int batchInsert (std::vector const*, size_t) override final; -//////////////////////////////////////////////////////////////////////////////// -/// @brief looks up edges using the index, restarting at the edge pointed at -/// by next -//////////////////////////////////////////////////////////////////////////////// - - void lookup (TRI_edge_index_iterator_t const*, - std::vector&, - TRI_doc_mptr_copy_t*&, - size_t); - int sizeHint (size_t) override final; bool hasBatchInsert () const override final {