File indexing completed on 2025-01-31 10:11:56
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef GOOGLE_PROTOBUF_COMPILER_CPP_OPTIONS_H__
0011 #define GOOGLE_PROTOBUF_COMPILER_CPP_OPTIONS_H__
0012
0013 #include <string>
0014
0015 #include "absl/container/flat_hash_set.h"
0016
0017 namespace google {
0018 namespace protobuf {
0019 namespace compiler {
0020 class AccessInfoMap;
0021 class SplitMap;
0022
0023 namespace cpp {
0024
0025 enum class EnforceOptimizeMode {
0026 kNoEnforcement,
0027 kSpeed,
0028 kCodeSize,
0029 kLiteRuntime,
0030 };
0031
0032 struct FieldListenerOptions {
0033 bool inject_field_listener_events = false;
0034 absl::flat_hash_set<std::string> forbidden_field_listener_events;
0035 };
0036
0037
0038 struct Options {
0039 const AccessInfoMap* access_info_map = nullptr;
0040 const SplitMap* split_map = nullptr;
0041 std::string dllexport_decl;
0042 std::string runtime_include_base;
0043 std::string annotation_pragma_name;
0044 std::string annotation_guard_name;
0045 FieldListenerOptions field_listener_options;
0046 EnforceOptimizeMode enforce_mode = EnforceOptimizeMode::kNoEnforcement;
0047 int num_cc_files = 0;
0048 bool safe_boundary_check = false;
0049 bool proto_h = false;
0050 bool transitive_pb_h = true;
0051 bool annotate_headers = false;
0052 bool lite_implicit_weak_fields = false;
0053 bool descriptor_implicit_weak_messages = false;
0054 bool bootstrap = false;
0055 bool opensource_runtime = false;
0056 bool annotate_accessor = false;
0057 bool force_split = false;
0058
0059
0060 bool profile_driven_cluster_aux_subtable = true;
0061 #ifdef PROTOBUF_STABLE_EXPERIMENTS
0062 bool force_eagerly_verified_lazy = true;
0063 bool force_inline_string = true;
0064 #else
0065 bool force_eagerly_verified_lazy = false;
0066 bool force_inline_string = false;
0067 #endif
0068 bool strip_nonfunctional_codegen = false;
0069 };
0070
0071 }
0072 }
0073 }
0074 }
0075
0076 #endif