blob: 4acea08697cd6fcdd272bdb93186d464dcc7993b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
#pragma once
namespace google {
namespace protobuf {
class Message;
}
}
namespace NProtoBuf {
using Message = ::google::protobuf::Message;
}
namespace NProtoBuf {
// Similiar to Message::MergeFrom, overwrites existing repeated fields
// and embedded messages completely instead of recursive merging.
void RewriteMerge(const Message& src, Message& dst);
// Does standard MergeFrom() by default, except messages/fields marked with DontMerge or DontMergeField option.
// Such fields are merged using RewriteMerge() (i.e. destination is cleared before merging anything from source)
void CustomMerge(const Message& src, Message& dst);
}
|