]> git.proxmox.com Git - ceph.git/blame - ceph/src/crimson/os/seastore/omap_manager.cc
update ceph source to reef 18.2.1
[ceph.git] / ceph / src / crimson / os / seastore / omap_manager.cc
CommitLineData
20effc67
TL
1// -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
2// vim: ts=8 sw=2 smarttab
3#include <experimental/iterator>
4#include <iostream>
5
6#include "crimson/os/seastore/transaction_manager.h"
7#include "crimson/os/seastore/omap_manager.h"
8#include "crimson/os/seastore/omap_manager/btree/btree_omap_manager.h"
9
10namespace crimson::os::seastore::omap_manager {
11
12OMapManagerRef create_omap_manager(TransactionManager &trans_manager) {
13 return OMapManagerRef(new BtreeOMapManager(trans_manager));
14}
15
16}
17
18namespace std {
19std::ostream &operator<<(std::ostream &out, const std::pair<std::string, std::string> &rhs)
20{
21 return out << "key_value_map (" << rhs.first<< "->" << rhs.second << ")";
22}
23}
24
25namespace crimson::os::seastore {
26
27std::ostream &operator<<(std::ostream &out, const std::list<std::string> &rhs)
28{
29 out << '[';
30 std::copy(std::begin(rhs), std::end(rhs), std::experimental::make_ostream_joiner(out, ", "));
31 return out << ']';
32}
33
34std::ostream &operator<<(std::ostream &out, const std::vector<std::pair<std::string, std::string>> &rhs)
35{
36 out << '[';
37 std::ostream_iterator<std::pair<std::string, std::string>> out_it(out, ", ");
38 std::copy(rhs.begin(), rhs.end(), out_it);
39 return out << ']';
40}
41
42}