18 void FilePacket::StartPacket ::
21 const char *
const sourcePath,
22 const char *
const destinationPath
26 this->header = header;
27 this->fileSize = fileSize;
28 this->sourcePath.initialize(sourcePath);
29 this->destinationPath.initialize(destinationPath);
32 U32 FilePacket::StartPacket ::
35 return this->header.bufferSize() +
36 sizeof(this->fileSize) +
37 this->sourcePath.bufferSize() +
38 this->destinationPath.bufferSize();
42 toBuffer(
Buffer& buffer)
const
48 return this->toSerialBuffer(serialBuffer);
66 this->sourcePath.fromSerialBuffer(serialBuffer);
73 this->destinationPath.fromSerialBuffer(serialBuffer);
83 toSerialBuffer(SerialBuffer& serialBuffer)
const
90 this->header.toSerialBuffer(serialBuffer);
97 serialBuffer.serialize(this->fileSize);
104 this->sourcePath.toSerialBuffer(serialBuffer);
111 this->destinationPath.toSerialBuffer(serialBuffer);
A variable-length serializable buffer.
SerializeStatus deserialize(U8 &val)
deserialize 8-bit unsigned int
SerializeStatus
forward declaration for string
@ FW_SERIALIZE_OK
Serialization/Deserialization operation was successful.