blob: 79523bb14a5e7675962412c043197c32195b9811 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
// Copyright (C) 2014 BMW Group
// Author: Lutz Bichler (lutz.bichler@bmw.de)
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
#ifndef VSOMEIP_PAYLOAD_IMPL_HPP
#define VSOMEIP_PAYLOAD_IMPL_HPP
#include <vsomeip/payload.hpp>
namespace vsomeip {
class payload_owner;
class serializer;
class deserializer;
class payload_impl : public payload {
public:
payload_impl();
payload_impl(const payload_owner *_owner);
payload_impl(const payload_impl& _payload);
virtual ~payload_impl();
byte_t * get_data();
const byte_t * get_data() const;
length_t get_length() const;
void set_capacity(length_t _capacity);
void set_data(const byte_t *_data, length_t _length);
void set_data(const std::vector< byte_t > &_data);
bool serialize(serializer *_to) const;
bool deserialize(deserializer *_from);
private:
std::vector< byte_t > data_;
const payload_owner *owner_;
};
} // namespace vsomeip
#endif // VSOMEIP_PAYLOAD_IMPL_HPP
|