0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
LoadRange.cc
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 
26 
27 #include <Common/Compat.h>
28 
29 #include "LoadRange.h"
30 
31 #include <Common/Logger.h>
32 #include <Common/Serialization.h>
33 
34 using namespace Hypertable;
36 
37 uint8_t LoadRange::encoding_version() const {
38  return 1;
39 }
40 
44 }
45 
70 void LoadRange::encode_internal(uint8_t **bufp) const {
71  m_table.encode(bufp);
72  m_range_spec.encode(bufp);
73  m_range_state.encode(bufp);
75 }
76 
77 void LoadRange::decode_internal(uint8_t version, const uint8_t **bufp,
78  size_t *remainp) {
79  m_table.decode(bufp, remainp);
80  m_range_spec.decode(bufp, remainp);
81  m_range_state.decode(bufp, remainp);
83 }
84 
85 
86 
Declarations for LoadRange request parameters.
void encode_internal(uint8_t **bufp) const override
Writes serialized representation of object to a buffer.
Definition: LoadRange.cc:70
virtual size_t encoded_length() const
Returns serialized object length.
Definition: Serializable.cc:37
size_t encoded_length_internal() const override
Returns internal serialized length.
Definition: LoadRange.cc:41
virtual void encode(uint8_t **bufp) const
Writes serialized representation of object to a buffer.
Definition: Serializable.cc:64
bool decode_bool(const uint8_t **bufp, size_t *remainp)
Decodes a boolean value from the given buffer.
Definition: Serialization.h:96
Logging routines and macros.
Compatibility Macros for C/C++.
uint8_t encoding_version() const override
Returns encoding version.
Definition: LoadRange.cc:37
Functions to serialize/deserialize primitives to/from a memory buffer.
virtual void decode(const uint8_t **bufp, size_t *remainp)
Reads serialized representation of object from a buffer.
Definition: Serializable.cc:70
Hypertable definitions
void encode_bool(uint8_t **bufp, bool bval)
Encodes a boolean into the given buffer.
Definition: Serialization.h:84
void decode_internal(uint8_t version, const uint8_t **bufp, size_t *remainp) override
Reads serialized representation of object from a buffer.
Definition: LoadRange.cc:77