PBUtils.h
1/* Distributed under the Apache License, Version 2.0.
2 See accompanying NOTICE file for details.*/
3
4#pragma once
5#include <google/protobuf/message.h>
6
7class CDM_DECL PBUtils
8{
9public:
10
11 static bool SerializeFromFile(const std::string& filename, google::protobuf::Message& dst, Logger* logger);
12 static bool SerializeToFile(const google::protobuf::Message& src, const std::string& filename, Logger* logger);
13
14 static bool SerializeFromString(const std::string& src, google::protobuf::Message& dst, eSerializationFormat m, Logger* logger);
15 static bool SerializeToString(const google::protobuf::Message& src, std::string& output, eSerializationFormat m, Logger* logger);
16
17 static void ProtobufLogHandler(google::protobuf::LogLevel level, const char* filename, int line, const std::string& message);
18};
Definition: Logger.h:71
Definition: PBUtils.h:8

Distributed under the Apache License, Version 2.0.

See accompanying NOTICE file for details.