#include <gridclientprotobufmarshaller.hpp>
List of all members.
Static Public Member Functions |
| static void | wrap (const GridAuthenticationRequestCommand &req, ObjectWrapper &obj) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageAuthenticationResult &resp) |
| static void | wrap (const GridLogRequestCommand &req, ObjectWrapper &obj) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageLogResult &resp) |
| static void | wrap (const GridTopologyRequestCommand &req, ObjectWrapper &obj) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageTopologyResult &resp) |
| static void | wrap (const GridCacheRequestCommand &req, ObjectWrapper &obj) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageCacheModifyResult &resp) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageCacheMetricResult &resp) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageCacheGetResult &) |
| static void | wrap (const GridTaskRequestCommand &req, ObjectWrapper &obj) |
| static void | unwrap (const ObjectWrapper &obj, GridClientMessageTaskResult &resp) |
| static void | marshal (const ::google::protobuf::Message &msg, std::vector< int8_t > &bytes) |
| static void | marshal (const std::string &str, std::vector< int8_t > &bytes) |
| static void | marshal (int64_t i64, std::vector< int8_t > &bytes) |
| static void | marshal (const GridClientUuid &uuid, std::vector< int8_t > &bytes) |
| static void | unmarshal (const std::vector< int8_t > &bytes,::google::protobuf::Message &msg) |
|
static const std::string & | msgType2Str (const ObjectWrapper &msg) |
| static void | marshalMsg (const ::google::protobuf::Message &msg, int8_t *&pBuffer, unsigned long &bufferLength) |
Detailed Description
Grid protobuf marshaler.
Member Function Documentation
| void GridClientProtobufMarshaller::marshal |
( |
const ::google::protobuf::Message & |
msg, |
|
|
std::vector< int8_t > & |
bytes | |
|
) |
| | [static] |
General marshaling function for converting protobuf message to byte array.
- Parameters:
-
| msg | Protobuf message to marshal. |
| bytes | Array to fill. |
| void GridClientProtobufMarshaller::marshal |
( |
const GridClientUuid & |
uuid, |
|
|
std::vector< int8_t > & |
bytes | |
|
) |
| | [static] |
Marshals UUID to byte vector.
- Parameters:
-
| uuid | An UUID to marshal. |
| bytes | Vector to fill. |
| void GridClientProtobufMarshaller::marshal |
( |
const std::string & |
str, |
|
|
std::vector< int8_t > & |
bytes | |
|
) |
| | [static] |
Marshals std::string to byte vector.
- Parameters:
-
| str | String to marshal. |
| bytes | Vector to fill. |
| void GridClientProtobufMarshaller::marshal |
( |
int64_t |
i64, |
|
|
std::vector< int8_t > & |
bytes | |
|
) |
| | [static] |
Marshals 64-bit integer to byte vector.
- Parameters:
-
| i64 | 64-bit integer to marshal. |
| bytes | Vector to fill. |
| void GridClientProtobufMarshaller::marshalMsg |
( |
const ::google::protobuf::Message & |
msg, |
|
|
int8_t *& |
pBuffer, |
|
|
unsigned long & |
bufferLength | |
|
) |
| | [static] |
Marshals a protobuf message to an array of bytes. Note that memory is allocated using new[] inside the call and caller is responsible for calling delete[] on the buffer
- Parameters:
-
| msg | Message to marshal. |
| pBuffer | - buffer to accept serialized message |
| bufferLength | - Length of data packed into buffer. Caller is responsible for calling delete[] on the buffer |
| void GridClientProtobufMarshaller::unmarshal |
( |
const std::vector< int8_t > & |
bytes, |
|
|
::google::protobuf::Message & |
msg | |
|
) |
| | [static] |
General unmarshaling function for converting byte array to protobuf message.
- Parameters:
-
| bytes | Binary data. |
| msg | Protobuf message to fill. |
Parses protobuf response into task call result.
- Parameters:
-
| obj | Data received from server. |
| resp | Task call response. |
Parses protobuf response into authentication result.
- Parameters:
-
| obj | Data received from server. |
| resp | Authentication response. |
Parses protobuf response into log result.
- Parameters:
-
| obj | Data received from server. |
| resp | Log response. |
Parses protobuf response into cache get result.
- Parameters:
-
| obj | Data received from server. |
| resp | Cache get response. |
Parses protobuf response into cache modification result.
- Parameters:
-
| obj | Data received from server. |
| resp | Cache modification response. |
Parses protobuf response into topology result.
- Parameters:
-
| obj | Data received from server. |
| resp | Topology response. |
Parses protobuf response into cache metrics result.
- Parameters:
-
| obj | Data received from server. |
| resp | Cache metrics response. |
Sets protobuf request parameters based on data from authentication request.
- Parameters:
-
| req | Authentication request. |
| obj | Protobuf object wrapper. |
Sets protobuf request parameters based on data from task call request.
- Parameters:
-
| req | Task call request. |
| obj | Protobuf object wrapper. |
| void GridClientProtobufMarshaller::wrap |
( |
const GridLogRequestCommand & |
req, |
|
|
ObjectWrapper & |
obj | |
|
) |
| | [static] |
Sets protobuf request parameters based on data from log request.
- Parameters:
-
| req | Authentication request. |
| obj | Protobuf object wrapper. |
Sets protobuf request parameters based on data from cache request.
- Parameters:
-
| req | Cache request. |
| obj | Protobuf object wrapper. |
Sets protobuf request parameters based on data from topology request.
- Parameters:
-
| req | Topology request. |
| obj | Protobuf object wrapper. |
The documentation for this class was generated from the following files: