File indexing completed on 2026-09-09 09:11:06
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef GOOGLE_PROTOBUF_UTIL_TYPE_RESOLVER_H__
0011 #define GOOGLE_PROTOBUF_UTIL_TYPE_RESOLVER_H__
0012
0013 #include <string>
0014
0015
0016
0017 #include "google/protobuf/any.pb.h" // IWYU pragma: keep
0018 #include "google/protobuf/type.pb.h"
0019 #include "absl/status/status.h"
0020 #include "google/protobuf/port.h"
0021
0022
0023
0024 #include "google/protobuf/port_def.inc"
0025
0026 namespace google {
0027 namespace protobuf {
0028 class DescriptorPool;
0029 namespace util {
0030
0031
0032
0033
0034 class PROTOBUF_EXPORT TypeResolver {
0035 public:
0036 TypeResolver() {}
0037 TypeResolver(const TypeResolver&) = delete;
0038 TypeResolver& operator=(const TypeResolver&) = delete;
0039 virtual ~TypeResolver() {}
0040
0041
0042 virtual absl::Status ResolveMessageType(
0043 const std::string& type_url, google::protobuf::Type* message_type) = 0;
0044
0045
0046 virtual absl::Status ResolveEnumType(const std::string& type_url,
0047 google::protobuf::Enum* enum_type) = 0;
0048 };
0049
0050 }
0051 }
0052 }
0053
0054 #include "google/protobuf/port_undef.inc"
0055
0056 #endif