0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
LoadThread.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2007-2015 Hypertable, Inc.
3  *
4  * This file is part of Hypertable.
5  *
6  * Hypertable is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public License
8  * as published by the Free Software Foundation; either version 3
9  * of the License, or any later version.
10  *
11  * Hypertable is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
19  * 02110-1301, USA.
20  */
21 
22 #ifndef Tools_load_generator_LoadThread_h
23 #define Tools_load_generator_LoadThread_h
24 
25 #include "ParallelLoad.h"
26 
27 #include <Hypertable/Lib/Table.h>
29 
30 #include <vector>
31 
32 namespace Hypertable {
33 
34  class LoadThread {
35 
36  public:
37  LoadThread(TablePtr &table, ::uint32_t mutator_flags,
38  ::uint64_t shared_mutator_flush_interval, ParallelStateRec &state)
39  : m_table(table), m_mutator_flags(mutator_flags),
40  m_shared_mutator_flush_interval(shared_mutator_flush_interval),
41  m_state(state) { }
42 
43  void operator()();
44 
45  private:
48  ::uint32_t m_mutator_flags;
51  };
52 
53 }
54 
55 #endif // Tools_load_generator_LoadThread_h
LoadThread(TablePtr &table,::uint32_t mutator_flags,::uint64_t shared_mutator_flush_interval, ParallelStateRec &state)
Definition: LoadThread.h:37
::uint32_t m_mutator_flags
Definition: LoadThread.h:48
::uint64_t m_shared_mutator_flush_interval
Definition: LoadThread.h:49
ParallelStateRec & m_state
Definition: LoadThread.h:50
TableMutatorPtr m_mutator
Definition: LoadThread.h:47
std::shared_ptr< TableMutator > TableMutatorPtr
Smart pointer to TableMutator.
Definition: TableMutator.h:257
Hypertable definitions
std::shared_ptr< Table > TablePtr
Definition: Table.h:53