PVData C++  8.0.6
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Static Public Member Functions | List of all members
epics::pvData::SerializeHelper Class Reference

Serialization helper. More...

#include <misc/pv/serializeHelper.h>

Static Public Member Functions

static void writeSize (std::size_t s, ByteBuffer *buffer, SerializableControl *flusher)
 
static std::size_t readSize (ByteBuffer *buffer, DeserializableControl *control)
 
static void serializeString (const std::string &value, ByteBuffer *buffer, SerializableControl *flusher)
 
static void serializeSubstring (const std::string &value, std::size_t offset, std::size_t count, ByteBuffer *buffer, SerializableControl *flusher)
 
static std::string deserializeString (ByteBuffer *buffer, DeserializableControl *control)
 

Detailed Description

Serialization helper.

Definition at line 29 of file serializeHelper.h.

Member Function Documentation

static std::string epics::pvData::SerializeHelper::deserializeString ( ByteBuffer buffer,
DeserializableControl control 
)
static

std::string deserialization helper method. TODO This method cannot return "null", but Java implementation could have serialized "null" value as well. We need to decide how to deserialize "null".

Parameters
[in]bufferdeserialization buffer
[in]controlcontrol
Returns
deserialized string
Todo:
This method cannot return "null", but Java implementation could have serialized "null" value as well. We need to decide how to deserialize "null".
static std::size_t epics::pvData::SerializeHelper::readSize ( ByteBuffer buffer,
DeserializableControl control 
)
static

Deserialize array size. The specified DeserializableControl ensures sufficient bytes are available.

Parameters
[in]bufferdeserialization buffer.
[in]controlthe DeserializableControl.
Returns
array size.
static void epics::pvData::SerializeHelper::serializeString ( const std::string value,
ByteBuffer buffer,
SerializableControl flusher 
)
static

std::string serialization helper method.

Parameters
[in]valuestd::string to serialize
[in]bufferserialization buffer
[in]flusherflusher
static void epics::pvData::SerializeHelper::serializeSubstring ( const std::string value,
std::size_t  offset,
std::size_t  count,
ByteBuffer buffer,
SerializableControl flusher 
)
static

std::string serialization helper method.

Parameters
[in]valuestd::string to serialize
[in]offsetstart of the substring in value
[in]countthe number of characters to write
[in]bufferserialization buffer
[in]flusherflusher
static void epics::pvData::SerializeHelper::writeSize ( std::size_t  s,
ByteBuffer buffer,
SerializableControl flusher 
)
static

Serialize the specified array size into the specified buffer, flushing when necessary. The specified SerializableControl manages any flushing required.

Parameters
[in]ssize to encode
[in]bufferserialization buffer
[in]flusherSerializableControl to manage the flushing

The documentation for this class was generated from the following file: