| 339 | |
| 340 | template<typename T> |
| 341 | static std::string packRepeatedField(const google::protobuf::RepeatedField<T>& values, |
| 342 | void (*doWrite)(google::protobuf::io::CodedOutputStream*, T)) { |
| 343 | std::string output; |
| 344 | google::protobuf::io::StringOutputStream outputStream(&output); |
| 345 | google::protobuf::io::CodedOutputStream codedOutputStream(&outputStream); |
| 346 | |
| 347 | for (const auto& value : values) { |
| 348 | doWrite(&codedOutputStream, value); |
| 349 | } |
| 350 | |
| 351 | return output; |
| 352 | } |
| 353 | |
| 354 | template<typename T> |
| 355 | static void writeRepeatedField(int fieldKey, |
no outgoing calls
no test coverage detected