0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
PhantomCommitComplete.h
Go to the documentation of this file.
1 /* -*- c++ -*-
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 
26 
27 #ifndef Hypertable_Lib_Master_Request_Parameters_PhantomCommitComplete_h
28 #define Hypertable_Lib_Master_Request_Parameters_PhantomCommitComplete_h
29 
30 #include <Common/Serializable.h>
31 
32 #include <string>
33 
34 using namespace std;
35 
36 namespace Hypertable {
37 namespace Lib {
38 namespace Master {
39 namespace Request {
40 namespace Parameters {
41 
44 
47  public:
48 
52 
63  PhantomCommitComplete(int64_t op_id, const string &location, int32_t plan_generation,
64  int32_t error, const string message)
65  : m_op_id(op_id), m_location(location),m_plan_generation(plan_generation),
66  m_error(error), m_message(message) { }
67 
70  int64_t op_id() { return m_op_id; }
71 
74  const string& location() const { return m_location; }
75 
78  int32_t plan_generation() { return m_plan_generation; }
79 
82  int32_t error() { return m_error; }
83 
86  const string& message() const { return m_message; }
87 
88  private:
89 
92  uint8_t encoding_version() const override;
93 
97  size_t encoded_length_internal() const override;
98 
101  void encode_internal(uint8_t **bufp) const override;
102 
109  void decode_internal(uint8_t version, const uint8_t **bufp,
110  size_t *remainp) override;
111 
113  int64_t m_op_id {};
114 
116  string m_location;
117 
119  int32_t m_plan_generation {};
120 
122  int32_t m_error {};
123 
125  string m_message;
126 
127  };
128 
130 
131 }}}}}
132 
133 #endif // Hypertable_Lib_Master_Request_Parameters_PhantomCommitComplete_h
STL namespace.
string m_location
Proxy name of RangeServer whose log is being recovered.
Request parameters for phantom commit complete operation.
PhantomCommitComplete(int64_t op_id, const string &location, int32_t plan_generation, int32_t error, const string message)
Constructor.
Declarations for Serializable.
Hypertable definitions
Mixin class that provides a standard serialization interface.
Definition: Serializable.h:65
const string & location() const
Gets proxy name of RangeServer whose log is being recovered.