diff --git a/src/include/storage/index/b_plus_tree.h b/src/include/storage/index/b_plus_tree.h index a2aa961d7..176fb5a28 100644 --- a/src/include/storage/index/b_plus_tree.h +++ b/src/include/storage/index/b_plus_tree.h @@ -22,7 +22,6 @@ #include "common/config.h" #include "common/macros.h" -#include "concurrency/transaction.h" #include "storage/index/index_iterator.h" #include "storage/page/b_plus_tree_header_page.h" #include "storage/page/b_plus_tree_internal_page.h" @@ -74,13 +73,13 @@ class BPlusTree { auto IsEmpty() const -> bool; // Insert a key-value pair into this B+ tree. - auto Insert(const KeyType &key, const ValueType &value, Transaction *txn = nullptr) -> bool; + auto Insert(const KeyType &key, const ValueType &value) -> bool; // Remove a key and its value from this B+ tree. - void Remove(const KeyType &key, Transaction *txn); + void Remove(const KeyType &key); // Return the value associated with a given key - auto GetValue(const KeyType &key, std::vector *result, Transaction *txn = nullptr) -> bool; + auto GetValue(const KeyType &key, std::vector *result) -> bool; // Return the page id of the root node auto GetRootPageId() -> page_id_t; @@ -112,10 +111,10 @@ class BPlusTree { auto DrawBPlusTree() -> std::string; // read data from file and insert one by one - void InsertFromFile(const std::filesystem::path &file_name, Transaction *txn = nullptr); + void InsertFromFile(const std::filesystem::path &file_name); // read data from file and remove one by one - void RemoveFromFile(const std::filesystem::path &file_name, Transaction *txn = nullptr); + void RemoveFromFile(const std::filesystem::path &file_name); /** * @brief Read batch operations from input file, below is a sample file format @@ -126,7 +125,7 @@ class BPlusTree { * (3) (7) * (1,2) (3,4) (5,6) (7,10,30) // The output tree example */ - void BatchOpsFromFile(const std::filesystem::path &file_name, Transaction *txn = nullptr); + void BatchOpsFromFile(const std::filesystem::path &file_name); private: /* Debug Routines for FREE!! */