diff options
Diffstat (limited to 'src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp')
-rw-r--r-- | src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp b/src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp index 867a093b3e0..719e187d548 100644 --- a/src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp +++ b/src/mongo/db/storage/in_memory/in_memory_btree_impl_test.cpp @@ -38,27 +38,24 @@ namespace mongo { - class InMemoryHarnessHelper final : public HarnessHelper { - public: - InMemoryHarnessHelper() - : _order( Ordering::make( BSONObj() ) ) { - } +class InMemoryHarnessHelper final : public HarnessHelper { +public: + InMemoryHarnessHelper() : _order(Ordering::make(BSONObj())) {} - std::unique_ptr<SortedDataInterface> newSortedDataInterface( bool unique ) final { - return std::unique_ptr<SortedDataInterface>(getInMemoryBtreeImpl(_order, &_data)); - } - - std::unique_ptr<RecoveryUnit> newRecoveryUnit() final { - return stdx::make_unique<InMemoryRecoveryUnit>(); - } - - private: - std::shared_ptr<void> _data; // used by InMemoryBtreeImpl - Ordering _order; - }; + std::unique_ptr<SortedDataInterface> newSortedDataInterface(bool unique) final { + return std::unique_ptr<SortedDataInterface>(getInMemoryBtreeImpl(_order, &_data)); + } - std::unique_ptr<HarnessHelper> newHarnessHelper() { - return stdx::make_unique<InMemoryHarnessHelper>(); + std::unique_ptr<RecoveryUnit> newRecoveryUnit() final { + return stdx::make_unique<InMemoryRecoveryUnit>(); } +private: + std::shared_ptr<void> _data; // used by InMemoryBtreeImpl + Ordering _order; +}; + +std::unique_ptr<HarnessHelper> newHarnessHelper() { + return stdx::make_unique<InMemoryHarnessHelper>(); +} } |