blob: 501bf3b134a220f56053a14325f64c3a0182cfb4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
// -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
// vim: ts=8 sw=2 smarttab
#include "include/interval_set.h"
#include "include/buffer.h"
#include <list>
#include <map>
#include <set>
#include "include/rados/librados.h"
#include "RadosModel.h"
#include "TestOpStat.h"
void TestOp::begin()
{
_begin();
}
void TestOp::finish(TestOp::CallbackInfo *info)
{
_finish(info);
}
void read_callback(librados::completion_t comp, void *arg) {
TestOp* op = static_cast<TestOp*>(arg);
op->finish(NULL);
}
void write_callback(librados::completion_t comp, void *arg) {
std::pair<TestOp*, TestOp::CallbackInfo*> *args =
static_cast<std::pair<TestOp*, TestOp::CallbackInfo*> *>(arg);
TestOp* op = args->first;
TestOp::CallbackInfo *info = args->second;
op->finish(info);
delete args;
delete info;
}
|