OLD | NEW |
1 // Generated by the protocol buffer compiler. DO NOT EDIT! | 1 // Generated by the protocol buffer compiler. DO NOT EDIT! |
2 // source: google/protobuf/struct.proto | 2 // source: google/protobuf/struct.proto |
3 | 3 |
4 #ifndef PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED | 4 #ifndef PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED |
5 #define PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED | 5 #define PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include <google/protobuf/stubs/common.h> | 9 #include <google/protobuf/stubs/common.h> |
10 | 10 |
11 #if GOOGLE_PROTOBUF_VERSION < 3000000 | 11 #if GOOGLE_PROTOBUF_VERSION < 3001000 |
12 #error This file was generated by a newer version of protoc which is | 12 #error This file was generated by a newer version of protoc which is |
13 #error incompatible with your Protocol Buffer headers. Please update | 13 #error incompatible with your Protocol Buffer headers. Please update |
14 #error your headers. | 14 #error your headers. |
15 #endif | 15 #endif |
16 #if 3000000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION | 16 #if 3001000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION |
17 #error This file was generated by an older version of protoc which is | 17 #error This file was generated by an older version of protoc which is |
18 #error incompatible with your Protocol Buffer headers. Please | 18 #error incompatible with your Protocol Buffer headers. Please |
19 #error regenerate this file with a newer version of protoc. | 19 #error regenerate this file with a newer version of protoc. |
20 #endif | 20 #endif |
21 | 21 |
22 #include <google/protobuf/arena.h> | 22 #include <google/protobuf/arena.h> |
23 #include <google/protobuf/arenastring.h> | 23 #include <google/protobuf/arenastring.h> |
24 #include <google/protobuf/generated_message_util.h> | 24 #include <google/protobuf/generated_message_util.h> |
25 #include <google/protobuf/metadata.h> | 25 #include <google/protobuf/metadata.h> |
26 #include <google/protobuf/message.h> | 26 #include <google/protobuf/message.h> |
27 #include <google/protobuf/repeated_field.h> | 27 #include <google/protobuf/repeated_field.h> // IWYU pragma: export |
28 #include <google/protobuf/extension_set.h> | 28 #include <google/protobuf/extension_set.h> // IWYU pragma: export |
29 #include <google/protobuf/map.h> | 29 #include <google/protobuf/map.h> |
30 #include <google/protobuf/map_field_inl.h> | 30 #include <google/protobuf/map_field_inl.h> |
31 #include <google/protobuf/generated_enum_reflection.h> | 31 #include <google/protobuf/generated_enum_reflection.h> |
32 #include <google/protobuf/unknown_field_set.h> | 32 #include <google/protobuf/unknown_field_set.h> |
33 // @@protoc_insertion_point(includes) | 33 // @@protoc_insertion_point(includes) |
| 34 namespace google { |
| 35 namespace protobuf { |
| 36 class ListValue; |
| 37 class ListValueDefaultTypeInternal; |
| 38 LIBPROTOBUF_EXPORT extern ListValueDefaultTypeInternal _ListValue_default_instan
ce_; |
| 39 class Struct; |
| 40 class StructDefaultTypeInternal; |
| 41 LIBPROTOBUF_EXPORT extern StructDefaultTypeInternal _Struct_default_instance_; |
| 42 class Value; |
| 43 class ValueDefaultTypeInternal; |
| 44 LIBPROTOBUF_EXPORT extern ValueDefaultTypeInternal _Value_default_instance_; |
| 45 } // namespace protobuf |
| 46 } // namespace google |
34 | 47 |
35 namespace google { | 48 namespace google { |
36 namespace protobuf { | 49 namespace protobuf { |
37 | 50 |
38 // Internal implementation detail -- do not call these. | 51 // Internal implementation detail -- do not call these. |
39 void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2eproto(); | 52 void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2eproto(); |
40 void protobuf_AssignDesc_google_2fprotobuf_2fstruct_2eproto(); | 53 void LIBPROTOBUF_EXPORT protobuf_InitDefaults_google_2fprotobuf_2fstruct_2eproto
(); |
41 void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); | |
42 | |
43 class ListValue; | |
44 class Struct; | |
45 class Value; | |
46 | 54 |
47 enum NullValue { | 55 enum NullValue { |
48 NULL_VALUE = 0, | 56 NULL_VALUE = 0, |
49 NullValue_INT_MIN_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32min, | 57 NullValue_INT_MIN_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32min, |
50 NullValue_INT_MAX_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32max | 58 NullValue_INT_MAX_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32max |
51 }; | 59 }; |
52 LIBPROTOBUF_EXPORT bool NullValue_IsValid(int value); | 60 LIBPROTOBUF_EXPORT bool NullValue_IsValid(int value); |
53 const NullValue NullValue_MIN = NULL_VALUE; | 61 const NullValue NullValue_MIN = NULL_VALUE; |
54 const NullValue NullValue_MAX = NULL_VALUE; | 62 const NullValue NullValue_MAX = NULL_VALUE; |
55 const int NullValue_ARRAYSIZE = NullValue_MAX + 1; | 63 const int NullValue_ARRAYSIZE = NullValue_MAX + 1; |
56 | 64 |
57 LIBPROTOBUF_EXPORT const ::google::protobuf::EnumDescriptor* NullValue_descripto
r(); | 65 LIBPROTOBUF_EXPORT const ::google::protobuf::EnumDescriptor* NullValue_descripto
r(); |
58 inline const ::std::string& NullValue_Name(NullValue value) { | 66 inline const ::std::string& NullValue_Name(NullValue value) { |
59 return ::google::protobuf::internal::NameOfEnum( | 67 return ::google::protobuf::internal::NameOfEnum( |
60 NullValue_descriptor(), value); | 68 NullValue_descriptor(), value); |
61 } | 69 } |
62 inline bool NullValue_Parse( | 70 inline bool NullValue_Parse( |
63 const ::std::string& name, NullValue* value) { | 71 const ::std::string& name, NullValue* value) { |
64 return ::google::protobuf::internal::ParseNamedEnum<NullValue>( | 72 return ::google::protobuf::internal::ParseNamedEnum<NullValue>( |
65 NullValue_descriptor(), name, value); | 73 NullValue_descriptor(), name, value); |
66 } | 74 } |
67 // =================================================================== | 75 // =================================================================== |
68 | 76 |
69 class LIBPROTOBUF_EXPORT Struct : public ::google::protobuf::Message { | 77 |
| 78 // ------------------------------------------------------------------- |
| 79 |
| 80 class LIBPROTOBUF_EXPORT Struct : public ::google::protobuf::Message /* @@protoc
_insertion_point(class_definition:google.protobuf.Struct) */ { |
70 public: | 81 public: |
71 Struct(); | 82 Struct(); |
72 virtual ~Struct(); | 83 virtual ~Struct(); |
73 | 84 |
74 Struct(const Struct& from); | 85 Struct(const Struct& from); |
75 | 86 |
76 inline Struct& operator=(const Struct& from) { | 87 inline Struct& operator=(const Struct& from) { |
77 CopyFrom(from); | 88 CopyFrom(from); |
78 return *this; | 89 return *this; |
79 } | 90 } |
80 | 91 |
| 92 inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { |
| 93 return GetArenaNoVirtual(); |
| 94 } |
| 95 inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { |
| 96 return MaybeArenaPtr(); |
| 97 } |
81 static const ::google::protobuf::Descriptor* descriptor(); | 98 static const ::google::protobuf::Descriptor* descriptor(); |
82 static const Struct& default_instance(); | 99 static const Struct& default_instance(); |
83 | 100 |
| 101 static inline const Struct* internal_default_instance() { |
| 102 return reinterpret_cast<const Struct*>( |
| 103 &_Struct_default_instance_); |
| 104 } |
| 105 |
| 106 void UnsafeArenaSwap(Struct* other); |
84 void Swap(Struct* other); | 107 void Swap(Struct* other); |
85 | 108 |
86 // implements Message ---------------------------------------------- | 109 // implements Message ---------------------------------------------- |
87 | 110 |
88 inline Struct* New() const { return New(NULL); } | 111 inline Struct* New() const PROTOBUF_FINAL { return New(NULL); } |
89 | 112 |
90 Struct* New(::google::protobuf::Arena* arena) const; | 113 Struct* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; |
91 void CopyFrom(const ::google::protobuf::Message& from); | 114 void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
92 void MergeFrom(const ::google::protobuf::Message& from); | 115 void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
93 void CopyFrom(const Struct& from); | 116 void CopyFrom(const Struct& from); |
94 void MergeFrom(const Struct& from); | 117 void MergeFrom(const Struct& from); |
95 void Clear(); | 118 void Clear() PROTOBUF_FINAL; |
96 bool IsInitialized() const; | 119 bool IsInitialized() const PROTOBUF_FINAL; |
97 | 120 |
98 int ByteSize() const; | 121 size_t ByteSizeLong() const PROTOBUF_FINAL; |
99 bool MergePartialFromCodedStream( | 122 bool MergePartialFromCodedStream( |
100 ::google::protobuf::io::CodedInputStream* input); | 123 ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; |
101 void SerializeWithCachedSizes( | 124 void SerializeWithCachedSizes( |
102 ::google::protobuf::io::CodedOutputStream* output) const; | 125 ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; |
103 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) const; | 126 ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( |
104 int GetCachedSize() const { return _cached_size_; } | 127 bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINA
L; |
| 128 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) |
| 129 const PROTOBUF_FINAL { |
| 130 return InternalSerializeWithCachedSizesToArray(false, output); |
| 131 } |
| 132 int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } |
105 private: | 133 private: |
106 void SharedCtor(); | 134 void SharedCtor(); |
107 void SharedDtor(); | 135 void SharedDtor(); |
108 void SetCachedSize(int size) const; | 136 void SetCachedSize(int size) const PROTOBUF_FINAL; |
109 void InternalSwap(Struct* other); | 137 void InternalSwap(Struct* other); |
| 138 protected: |
| 139 explicit Struct(::google::protobuf::Arena* arena); |
| 140 private: |
| 141 static void ArenaDtor(void* object); |
| 142 inline void RegisterArenaDtor(::google::protobuf::Arena* arena); |
110 private: | 143 private: |
111 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { | 144 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { |
112 return _internal_metadata_.arena(); | 145 return _internal_metadata_.arena(); |
113 } | 146 } |
114 inline void* MaybeArenaPtr() const { | 147 inline void* MaybeArenaPtr() const { |
115 return _internal_metadata_.raw_arena_ptr(); | 148 return _internal_metadata_.raw_arena_ptr(); |
116 } | 149 } |
117 public: | 150 public: |
118 | 151 |
119 ::google::protobuf::Metadata GetMetadata() const; | 152 ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; |
120 | 153 |
121 // nested types ---------------------------------------------------- | 154 // nested types ---------------------------------------------------- |
122 | 155 |
123 | 156 |
124 // accessors ------------------------------------------------------- | 157 // accessors ------------------------------------------------------- |
125 | 158 |
126 // map<string, .google.protobuf.Value> fields = 1; | 159 // map<string, .google.protobuf.Value> fields = 1; |
127 int fields_size() const; | 160 int fields_size() const; |
128 void clear_fields(); | 161 void clear_fields(); |
129 static const int kFieldsFieldNumber = 1; | 162 static const int kFieldsFieldNumber = 1; |
130 const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >& | 163 const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >& |
131 fields() const; | 164 fields() const; |
132 ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* | 165 ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* |
133 mutable_fields(); | 166 mutable_fields(); |
134 | 167 |
135 // @@protoc_insertion_point(class_scope:google.protobuf.Struct) | 168 // @@protoc_insertion_point(class_scope:google.protobuf.Struct) |
136 private: | 169 private: |
137 | 170 |
138 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; | 171 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; |
139 bool _is_default_instance_; | 172 friend class ::google::protobuf::Arena; |
| 173 typedef void InternalArenaConstructable_; |
| 174 typedef void DestructorSkippable_; |
140 typedef ::google::protobuf::internal::MapEntryLite< | 175 typedef ::google::protobuf::internal::MapEntryLite< |
141 ::std::string, ::google::protobuf::Value, | 176 ::std::string, ::google::protobuf::Value, |
142 ::google::protobuf::internal::WireFormatLite::TYPE_STRING, | 177 ::google::protobuf::internal::WireFormatLite::TYPE_STRING, |
143 ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, | 178 ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, |
144 0 > | 179 0 > |
145 Struct_FieldsEntry; | 180 Struct_FieldsEntry; |
146 ::google::protobuf::internal::MapField< | 181 ::google::protobuf::internal::MapField< |
147 ::std::string, ::google::protobuf::Value, | 182 ::std::string, ::google::protobuf::Value, |
148 ::google::protobuf::internal::WireFormatLite::TYPE_STRING, | 183 ::google::protobuf::internal::WireFormatLite::TYPE_STRING, |
149 ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, | 184 ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, |
150 0 > fields_; | 185 0 > fields_; |
151 mutable int _cached_size_; | 186 mutable int _cached_size_; |
152 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto(); | 187 friend void LIBPROTOBUF_EXPORT protobuf_InitDefaults_google_2fprotobuf_2fstruc
t_2eproto_impl(); |
153 friend void protobuf_AssignDesc_google_2fprotobuf_2fstruct_2eproto(); | 188 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto_impl(); |
| 189 friend const ::google::protobuf::uint32* protobuf_Offsets_google_2fprotobuf_2f
struct_2eproto(); |
154 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); | 190 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); |
155 | 191 |
156 void InitAsDefaultInstance(); | |
157 static Struct* default_instance_; | |
158 }; | 192 }; |
159 // ------------------------------------------------------------------- | 193 // ------------------------------------------------------------------- |
160 | 194 |
161 class LIBPROTOBUF_EXPORT Value : public ::google::protobuf::Message { | 195 class LIBPROTOBUF_EXPORT Value : public ::google::protobuf::Message /* @@protoc_
insertion_point(class_definition:google.protobuf.Value) */ { |
162 public: | 196 public: |
163 Value(); | 197 Value(); |
164 virtual ~Value(); | 198 virtual ~Value(); |
165 | 199 |
166 Value(const Value& from); | 200 Value(const Value& from); |
167 | 201 |
168 inline Value& operator=(const Value& from) { | 202 inline Value& operator=(const Value& from) { |
169 CopyFrom(from); | 203 CopyFrom(from); |
170 return *this; | 204 return *this; |
171 } | 205 } |
172 | 206 |
| 207 inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { |
| 208 return GetArenaNoVirtual(); |
| 209 } |
| 210 inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { |
| 211 return MaybeArenaPtr(); |
| 212 } |
173 static const ::google::protobuf::Descriptor* descriptor(); | 213 static const ::google::protobuf::Descriptor* descriptor(); |
174 static const Value& default_instance(); | 214 static const Value& default_instance(); |
175 | 215 |
176 enum KindCase { | 216 enum KindCase { |
177 kNullValue = 1, | 217 kNullValue = 1, |
178 kNumberValue = 2, | 218 kNumberValue = 2, |
179 kStringValue = 3, | 219 kStringValue = 3, |
180 kBoolValue = 4, | 220 kBoolValue = 4, |
181 kStructValue = 5, | 221 kStructValue = 5, |
182 kListValue = 6, | 222 kListValue = 6, |
183 KIND_NOT_SET = 0, | 223 KIND_NOT_SET = 0, |
184 }; | 224 }; |
185 | 225 |
| 226 static inline const Value* internal_default_instance() { |
| 227 return reinterpret_cast<const Value*>( |
| 228 &_Value_default_instance_); |
| 229 } |
| 230 |
| 231 void UnsafeArenaSwap(Value* other); |
186 void Swap(Value* other); | 232 void Swap(Value* other); |
187 | 233 |
188 // implements Message ---------------------------------------------- | 234 // implements Message ---------------------------------------------- |
189 | 235 |
190 inline Value* New() const { return New(NULL); } | 236 inline Value* New() const PROTOBUF_FINAL { return New(NULL); } |
191 | 237 |
192 Value* New(::google::protobuf::Arena* arena) const; | 238 Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; |
193 void CopyFrom(const ::google::protobuf::Message& from); | 239 void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
194 void MergeFrom(const ::google::protobuf::Message& from); | 240 void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
195 void CopyFrom(const Value& from); | 241 void CopyFrom(const Value& from); |
196 void MergeFrom(const Value& from); | 242 void MergeFrom(const Value& from); |
197 void Clear(); | 243 void Clear() PROTOBUF_FINAL; |
198 bool IsInitialized() const; | 244 bool IsInitialized() const PROTOBUF_FINAL; |
199 | 245 |
200 int ByteSize() const; | 246 size_t ByteSizeLong() const PROTOBUF_FINAL; |
201 bool MergePartialFromCodedStream( | 247 bool MergePartialFromCodedStream( |
202 ::google::protobuf::io::CodedInputStream* input); | 248 ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; |
203 void SerializeWithCachedSizes( | 249 void SerializeWithCachedSizes( |
204 ::google::protobuf::io::CodedOutputStream* output) const; | 250 ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; |
205 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) const; | 251 ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( |
206 int GetCachedSize() const { return _cached_size_; } | 252 bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINA
L; |
| 253 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) |
| 254 const PROTOBUF_FINAL { |
| 255 return InternalSerializeWithCachedSizesToArray(false, output); |
| 256 } |
| 257 int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } |
207 private: | 258 private: |
208 void SharedCtor(); | 259 void SharedCtor(); |
209 void SharedDtor(); | 260 void SharedDtor(); |
210 void SetCachedSize(int size) const; | 261 void SetCachedSize(int size) const PROTOBUF_FINAL; |
211 void InternalSwap(Value* other); | 262 void InternalSwap(Value* other); |
| 263 protected: |
| 264 explicit Value(::google::protobuf::Arena* arena); |
| 265 private: |
| 266 static void ArenaDtor(void* object); |
| 267 inline void RegisterArenaDtor(::google::protobuf::Arena* arena); |
212 private: | 268 private: |
213 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { | 269 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { |
214 return _internal_metadata_.arena(); | 270 return _internal_metadata_.arena(); |
215 } | 271 } |
216 inline void* MaybeArenaPtr() const { | 272 inline void* MaybeArenaPtr() const { |
217 return _internal_metadata_.raw_arena_ptr(); | 273 return _internal_metadata_.raw_arena_ptr(); |
218 } | 274 } |
219 public: | 275 public: |
220 | 276 |
221 ::google::protobuf::Metadata GetMetadata() const; | 277 ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; |
222 | 278 |
223 // nested types ---------------------------------------------------- | 279 // nested types ---------------------------------------------------- |
224 | 280 |
225 // accessors ------------------------------------------------------- | 281 // accessors ------------------------------------------------------- |
226 | 282 |
227 // optional .google.protobuf.NullValue null_value = 1; | 283 // .google.protobuf.NullValue null_value = 1; |
228 private: | 284 private: |
229 bool has_null_value() const; | 285 bool has_null_value() const; |
230 public: | 286 public: |
231 void clear_null_value(); | 287 void clear_null_value(); |
232 static const int kNullValueFieldNumber = 1; | 288 static const int kNullValueFieldNumber = 1; |
233 ::google::protobuf::NullValue null_value() const; | 289 ::google::protobuf::NullValue null_value() const; |
234 void set_null_value(::google::protobuf::NullValue value); | 290 void set_null_value(::google::protobuf::NullValue value); |
235 | 291 |
236 // optional double number_value = 2; | 292 // double number_value = 2; |
237 private: | 293 private: |
238 bool has_number_value() const; | 294 bool has_number_value() const; |
239 public: | 295 public: |
240 void clear_number_value(); | 296 void clear_number_value(); |
241 static const int kNumberValueFieldNumber = 2; | 297 static const int kNumberValueFieldNumber = 2; |
242 double number_value() const; | 298 double number_value() const; |
243 void set_number_value(double value); | 299 void set_number_value(double value); |
244 | 300 |
245 // optional string string_value = 3; | 301 // string string_value = 3; |
246 private: | 302 private: |
247 bool has_string_value() const; | 303 bool has_string_value() const; |
248 public: | 304 public: |
249 void clear_string_value(); | 305 void clear_string_value(); |
250 static const int kStringValueFieldNumber = 3; | 306 static const int kStringValueFieldNumber = 3; |
251 const ::std::string& string_value() const; | 307 const ::std::string& string_value() const; |
252 void set_string_value(const ::std::string& value); | 308 void set_string_value(const ::std::string& value); |
253 void set_string_value(const char* value); | 309 void set_string_value(const char* value); |
254 void set_string_value(const char* value, size_t size); | 310 void set_string_value(const char* value, size_t size); |
255 ::std::string* mutable_string_value(); | 311 ::std::string* mutable_string_value(); |
256 ::std::string* release_string_value(); | 312 ::std::string* release_string_value(); |
257 void set_allocated_string_value(::std::string* string_value); | 313 void set_allocated_string_value(::std::string* string_value); |
| 314 ::std::string* unsafe_arena_release_string_value(); |
| 315 void unsafe_arena_set_allocated_string_value( |
| 316 ::std::string* string_value); |
258 | 317 |
259 // optional bool bool_value = 4; | 318 // bool bool_value = 4; |
260 private: | 319 private: |
261 bool has_bool_value() const; | 320 bool has_bool_value() const; |
262 public: | 321 public: |
263 void clear_bool_value(); | 322 void clear_bool_value(); |
264 static const int kBoolValueFieldNumber = 4; | 323 static const int kBoolValueFieldNumber = 4; |
265 bool bool_value() const; | 324 bool bool_value() const; |
266 void set_bool_value(bool value); | 325 void set_bool_value(bool value); |
267 | 326 |
268 // optional .google.protobuf.Struct struct_value = 5; | 327 // .google.protobuf.Struct struct_value = 5; |
269 bool has_struct_value() const; | 328 bool has_struct_value() const; |
270 void clear_struct_value(); | 329 void clear_struct_value(); |
271 static const int kStructValueFieldNumber = 5; | 330 static const int kStructValueFieldNumber = 5; |
| 331 private: |
| 332 void _slow_mutable_struct_value(); |
| 333 void _slow_set_allocated_struct_value( |
| 334 ::google::protobuf::Arena* message_arena, ::google::protobuf::Struct** str
uct_value); |
| 335 ::google::protobuf::Struct* _slow_release_struct_value(); |
| 336 public: |
272 const ::google::protobuf::Struct& struct_value() const; | 337 const ::google::protobuf::Struct& struct_value() const; |
273 ::google::protobuf::Struct* mutable_struct_value(); | 338 ::google::protobuf::Struct* mutable_struct_value(); |
274 ::google::protobuf::Struct* release_struct_value(); | 339 ::google::protobuf::Struct* release_struct_value(); |
275 void set_allocated_struct_value(::google::protobuf::Struct* struct_value); | 340 void set_allocated_struct_value(::google::protobuf::Struct* struct_value); |
| 341 ::google::protobuf::Struct* unsafe_arena_release_struct_value(); |
| 342 void unsafe_arena_set_allocated_struct_value( |
| 343 ::google::protobuf::Struct* struct_value); |
276 | 344 |
277 // optional .google.protobuf.ListValue list_value = 6; | 345 // .google.protobuf.ListValue list_value = 6; |
278 bool has_list_value() const; | 346 bool has_list_value() const; |
279 void clear_list_value(); | 347 void clear_list_value(); |
280 static const int kListValueFieldNumber = 6; | 348 static const int kListValueFieldNumber = 6; |
| 349 private: |
| 350 void _slow_mutable_list_value(); |
| 351 void _slow_set_allocated_list_value( |
| 352 ::google::protobuf::Arena* message_arena, ::google::protobuf::ListValue**
list_value); |
| 353 ::google::protobuf::ListValue* _slow_release_list_value(); |
| 354 public: |
281 const ::google::protobuf::ListValue& list_value() const; | 355 const ::google::protobuf::ListValue& list_value() const; |
282 ::google::protobuf::ListValue* mutable_list_value(); | 356 ::google::protobuf::ListValue* mutable_list_value(); |
283 ::google::protobuf::ListValue* release_list_value(); | 357 ::google::protobuf::ListValue* release_list_value(); |
284 void set_allocated_list_value(::google::protobuf::ListValue* list_value); | 358 void set_allocated_list_value(::google::protobuf::ListValue* list_value); |
| 359 ::google::protobuf::ListValue* unsafe_arena_release_list_value(); |
| 360 void unsafe_arena_set_allocated_list_value( |
| 361 ::google::protobuf::ListValue* list_value); |
285 | 362 |
286 KindCase kind_case() const; | 363 KindCase kind_case() const; |
287 // @@protoc_insertion_point(class_scope:google.protobuf.Value) | 364 // @@protoc_insertion_point(class_scope:google.protobuf.Value) |
288 private: | 365 private: |
289 inline void set_has_null_value(); | 366 void set_has_null_value(); |
290 inline void set_has_number_value(); | 367 void set_has_number_value(); |
291 inline void set_has_string_value(); | 368 void set_has_string_value(); |
292 inline void set_has_bool_value(); | 369 void set_has_bool_value(); |
293 inline void set_has_struct_value(); | 370 void set_has_struct_value(); |
294 inline void set_has_list_value(); | 371 void set_has_list_value(); |
295 | 372 |
296 inline bool has_kind() const; | 373 inline bool has_kind() const; |
297 void clear_kind(); | 374 void clear_kind(); |
298 inline void clear_has_kind(); | 375 inline void clear_has_kind(); |
299 | 376 |
300 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; | 377 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; |
301 bool _is_default_instance_; | 378 friend class ::google::protobuf::Arena; |
| 379 typedef void InternalArenaConstructable_; |
| 380 typedef void DestructorSkippable_; |
302 union KindUnion { | 381 union KindUnion { |
303 KindUnion() {} | 382 KindUnion() {} |
304 int null_value_; | 383 int null_value_; |
305 double number_value_; | 384 double number_value_; |
306 ::google::protobuf::internal::ArenaStringPtr string_value_; | 385 ::google::protobuf::internal::ArenaStringPtr string_value_; |
307 bool bool_value_; | 386 bool bool_value_; |
308 ::google::protobuf::Struct* struct_value_; | 387 ::google::protobuf::Struct* struct_value_; |
309 ::google::protobuf::ListValue* list_value_; | 388 ::google::protobuf::ListValue* list_value_; |
310 } kind_; | 389 } kind_; |
311 mutable int _cached_size_; | 390 mutable int _cached_size_; |
312 ::google::protobuf::uint32 _oneof_case_[1]; | 391 ::google::protobuf::uint32 _oneof_case_[1]; |
313 | 392 |
314 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto(); | 393 friend void LIBPROTOBUF_EXPORT protobuf_InitDefaults_google_2fprotobuf_2fstruc
t_2eproto_impl(); |
315 friend void protobuf_AssignDesc_google_2fprotobuf_2fstruct_2eproto(); | 394 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto_impl(); |
| 395 friend const ::google::protobuf::uint32* protobuf_Offsets_google_2fprotobuf_2f
struct_2eproto(); |
316 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); | 396 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); |
317 | 397 |
318 void InitAsDefaultInstance(); | |
319 static Value* default_instance_; | |
320 }; | 398 }; |
321 // ------------------------------------------------------------------- | 399 // ------------------------------------------------------------------- |
322 | 400 |
323 class LIBPROTOBUF_EXPORT ListValue : public ::google::protobuf::Message { | 401 class LIBPROTOBUF_EXPORT ListValue : public ::google::protobuf::Message /* @@pro
toc_insertion_point(class_definition:google.protobuf.ListValue) */ { |
324 public: | 402 public: |
325 ListValue(); | 403 ListValue(); |
326 virtual ~ListValue(); | 404 virtual ~ListValue(); |
327 | 405 |
328 ListValue(const ListValue& from); | 406 ListValue(const ListValue& from); |
329 | 407 |
330 inline ListValue& operator=(const ListValue& from) { | 408 inline ListValue& operator=(const ListValue& from) { |
331 CopyFrom(from); | 409 CopyFrom(from); |
332 return *this; | 410 return *this; |
333 } | 411 } |
334 | 412 |
| 413 inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { |
| 414 return GetArenaNoVirtual(); |
| 415 } |
| 416 inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { |
| 417 return MaybeArenaPtr(); |
| 418 } |
335 static const ::google::protobuf::Descriptor* descriptor(); | 419 static const ::google::protobuf::Descriptor* descriptor(); |
336 static const ListValue& default_instance(); | 420 static const ListValue& default_instance(); |
337 | 421 |
| 422 static inline const ListValue* internal_default_instance() { |
| 423 return reinterpret_cast<const ListValue*>( |
| 424 &_ListValue_default_instance_); |
| 425 } |
| 426 |
| 427 void UnsafeArenaSwap(ListValue* other); |
338 void Swap(ListValue* other); | 428 void Swap(ListValue* other); |
339 | 429 |
340 // implements Message ---------------------------------------------- | 430 // implements Message ---------------------------------------------- |
341 | 431 |
342 inline ListValue* New() const { return New(NULL); } | 432 inline ListValue* New() const PROTOBUF_FINAL { return New(NULL); } |
343 | 433 |
344 ListValue* New(::google::protobuf::Arena* arena) const; | 434 ListValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; |
345 void CopyFrom(const ::google::protobuf::Message& from); | 435 void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
346 void MergeFrom(const ::google::protobuf::Message& from); | 436 void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; |
347 void CopyFrom(const ListValue& from); | 437 void CopyFrom(const ListValue& from); |
348 void MergeFrom(const ListValue& from); | 438 void MergeFrom(const ListValue& from); |
349 void Clear(); | 439 void Clear() PROTOBUF_FINAL; |
350 bool IsInitialized() const; | 440 bool IsInitialized() const PROTOBUF_FINAL; |
351 | 441 |
352 int ByteSize() const; | 442 size_t ByteSizeLong() const PROTOBUF_FINAL; |
353 bool MergePartialFromCodedStream( | 443 bool MergePartialFromCodedStream( |
354 ::google::protobuf::io::CodedInputStream* input); | 444 ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; |
355 void SerializeWithCachedSizes( | 445 void SerializeWithCachedSizes( |
356 ::google::protobuf::io::CodedOutputStream* output) const; | 446 ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; |
357 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) const; | 447 ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( |
358 int GetCachedSize() const { return _cached_size_; } | 448 bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINA
L; |
| 449 ::google::protobuf::uint8* SerializeWithCachedSizesToArray(::google::protobuf:
:uint8* output) |
| 450 const PROTOBUF_FINAL { |
| 451 return InternalSerializeWithCachedSizesToArray(false, output); |
| 452 } |
| 453 int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } |
359 private: | 454 private: |
360 void SharedCtor(); | 455 void SharedCtor(); |
361 void SharedDtor(); | 456 void SharedDtor(); |
362 void SetCachedSize(int size) const; | 457 void SetCachedSize(int size) const PROTOBUF_FINAL; |
363 void InternalSwap(ListValue* other); | 458 void InternalSwap(ListValue* other); |
| 459 protected: |
| 460 explicit ListValue(::google::protobuf::Arena* arena); |
| 461 private: |
| 462 static void ArenaDtor(void* object); |
| 463 inline void RegisterArenaDtor(::google::protobuf::Arena* arena); |
364 private: | 464 private: |
365 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { | 465 inline ::google::protobuf::Arena* GetArenaNoVirtual() const { |
366 return _internal_metadata_.arena(); | 466 return _internal_metadata_.arena(); |
367 } | 467 } |
368 inline void* MaybeArenaPtr() const { | 468 inline void* MaybeArenaPtr() const { |
369 return _internal_metadata_.raw_arena_ptr(); | 469 return _internal_metadata_.raw_arena_ptr(); |
370 } | 470 } |
371 public: | 471 public: |
372 | 472 |
373 ::google::protobuf::Metadata GetMetadata() const; | 473 ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; |
374 | 474 |
375 // nested types ---------------------------------------------------- | 475 // nested types ---------------------------------------------------- |
376 | 476 |
377 // accessors ------------------------------------------------------- | 477 // accessors ------------------------------------------------------- |
378 | 478 |
379 // repeated .google.protobuf.Value values = 1; | 479 // repeated .google.protobuf.Value values = 1; |
380 int values_size() const; | 480 int values_size() const; |
381 void clear_values(); | 481 void clear_values(); |
382 static const int kValuesFieldNumber = 1; | 482 static const int kValuesFieldNumber = 1; |
383 const ::google::protobuf::Value& values(int index) const; | 483 const ::google::protobuf::Value& values(int index) const; |
384 ::google::protobuf::Value* mutable_values(int index); | 484 ::google::protobuf::Value* mutable_values(int index); |
385 ::google::protobuf::Value* add_values(); | 485 ::google::protobuf::Value* add_values(); |
386 ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >* | 486 ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >* |
387 mutable_values(); | 487 mutable_values(); |
388 const ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >& | 488 const ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >& |
389 values() const; | 489 values() const; |
390 | 490 |
391 // @@protoc_insertion_point(class_scope:google.protobuf.ListValue) | 491 // @@protoc_insertion_point(class_scope:google.protobuf.ListValue) |
392 private: | 492 private: |
393 | 493 |
394 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; | 494 ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; |
395 bool _is_default_instance_; | 495 friend class ::google::protobuf::Arena; |
| 496 typedef void InternalArenaConstructable_; |
| 497 typedef void DestructorSkippable_; |
396 ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value > values_; | 498 ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value > values_; |
397 mutable int _cached_size_; | 499 mutable int _cached_size_; |
398 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto(); | 500 friend void LIBPROTOBUF_EXPORT protobuf_InitDefaults_google_2fprotobuf_2fstruc
t_2eproto_impl(); |
399 friend void protobuf_AssignDesc_google_2fprotobuf_2fstruct_2eproto(); | 501 friend void LIBPROTOBUF_EXPORT protobuf_AddDesc_google_2fprotobuf_2fstruct_2ep
roto_impl(); |
| 502 friend const ::google::protobuf::uint32* protobuf_Offsets_google_2fprotobuf_2f
struct_2eproto(); |
400 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); | 503 friend void protobuf_ShutdownFile_google_2fprotobuf_2fstruct_2eproto(); |
401 | 504 |
402 void InitAsDefaultInstance(); | |
403 static ListValue* default_instance_; | |
404 }; | 505 }; |
405 // =================================================================== | 506 // =================================================================== |
406 | 507 |
407 | 508 |
408 // =================================================================== | 509 // =================================================================== |
409 | 510 |
410 #if !PROTOBUF_INLINE_NOT_IN_HEADERS | 511 #if !PROTOBUF_INLINE_NOT_IN_HEADERS |
| 512 // ------------------------------------------------------------------- |
| 513 |
411 // Struct | 514 // Struct |
412 | 515 |
413 // map<string, .google.protobuf.Value> fields = 1; | 516 // map<string, .google.protobuf.Value> fields = 1; |
414 inline int Struct::fields_size() const { | 517 inline int Struct::fields_size() const { |
415 return fields_.size(); | 518 return fields_.size(); |
416 } | 519 } |
417 inline void Struct::clear_fields() { | 520 inline void Struct::clear_fields() { |
418 fields_.Clear(); | 521 fields_.Clear(); |
419 } | 522 } |
420 inline const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >
& | 523 inline const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >
& |
421 Struct::fields() const { | 524 Struct::fields() const { |
422 // @@protoc_insertion_point(field_map:google.protobuf.Struct.fields) | 525 // @@protoc_insertion_point(field_map:google.protobuf.Struct.fields) |
423 return fields_.GetMap(); | 526 return fields_.GetMap(); |
424 } | 527 } |
425 inline ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* | 528 inline ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* |
426 Struct::mutable_fields() { | 529 Struct::mutable_fields() { |
427 // @@protoc_insertion_point(field_mutable_map:google.protobuf.Struct.fields) | 530 // @@protoc_insertion_point(field_mutable_map:google.protobuf.Struct.fields) |
428 return fields_.MutableMap(); | 531 return fields_.MutableMap(); |
429 } | 532 } |
430 | 533 |
431 // ------------------------------------------------------------------- | 534 // ------------------------------------------------------------------- |
432 | 535 |
433 // Value | 536 // Value |
434 | 537 |
435 // optional .google.protobuf.NullValue null_value = 1; | 538 // .google.protobuf.NullValue null_value = 1; |
436 inline bool Value::has_null_value() const { | 539 inline bool Value::has_null_value() const { |
437 return kind_case() == kNullValue; | 540 return kind_case() == kNullValue; |
438 } | 541 } |
439 inline void Value::set_has_null_value() { | 542 inline void Value::set_has_null_value() { |
440 _oneof_case_[0] = kNullValue; | 543 _oneof_case_[0] = kNullValue; |
441 } | 544 } |
442 inline void Value::clear_null_value() { | 545 inline void Value::clear_null_value() { |
443 if (has_null_value()) { | 546 if (has_null_value()) { |
444 kind_.null_value_ = 0; | 547 kind_.null_value_ = 0; |
445 clear_has_kind(); | 548 clear_has_kind(); |
446 } | 549 } |
447 } | 550 } |
448 inline ::google::protobuf::NullValue Value::null_value() const { | 551 inline ::google::protobuf::NullValue Value::null_value() const { |
449 // @@protoc_insertion_point(field_get:google.protobuf.Value.null_value) | 552 // @@protoc_insertion_point(field_get:google.protobuf.Value.null_value) |
450 if (has_null_value()) { | 553 if (has_null_value()) { |
451 return static_cast< ::google::protobuf::NullValue >(kind_.null_value_); | 554 return static_cast< ::google::protobuf::NullValue >(kind_.null_value_); |
452 } | 555 } |
453 return static_cast< ::google::protobuf::NullValue >(0); | 556 return static_cast< ::google::protobuf::NullValue >(0); |
454 } | 557 } |
455 inline void Value::set_null_value(::google::protobuf::NullValue value) { | 558 inline void Value::set_null_value(::google::protobuf::NullValue value) { |
456 if (!has_null_value()) { | 559 if (!has_null_value()) { |
457 clear_kind(); | 560 clear_kind(); |
458 set_has_null_value(); | 561 set_has_null_value(); |
459 } | 562 } |
460 kind_.null_value_ = value; | 563 kind_.null_value_ = value; |
461 // @@protoc_insertion_point(field_set:google.protobuf.Value.null_value) | 564 // @@protoc_insertion_point(field_set:google.protobuf.Value.null_value) |
462 } | 565 } |
463 | 566 |
464 // optional double number_value = 2; | 567 // double number_value = 2; |
465 inline bool Value::has_number_value() const { | 568 inline bool Value::has_number_value() const { |
466 return kind_case() == kNumberValue; | 569 return kind_case() == kNumberValue; |
467 } | 570 } |
468 inline void Value::set_has_number_value() { | 571 inline void Value::set_has_number_value() { |
469 _oneof_case_[0] = kNumberValue; | 572 _oneof_case_[0] = kNumberValue; |
470 } | 573 } |
471 inline void Value::clear_number_value() { | 574 inline void Value::clear_number_value() { |
472 if (has_number_value()) { | 575 if (has_number_value()) { |
473 kind_.number_value_ = 0; | 576 kind_.number_value_ = 0; |
474 clear_has_kind(); | 577 clear_has_kind(); |
475 } | 578 } |
476 } | 579 } |
477 inline double Value::number_value() const { | 580 inline double Value::number_value() const { |
478 // @@protoc_insertion_point(field_get:google.protobuf.Value.number_value) | 581 // @@protoc_insertion_point(field_get:google.protobuf.Value.number_value) |
479 if (has_number_value()) { | 582 if (has_number_value()) { |
480 return kind_.number_value_; | 583 return kind_.number_value_; |
481 } | 584 } |
482 return 0; | 585 return 0; |
483 } | 586 } |
484 inline void Value::set_number_value(double value) { | 587 inline void Value::set_number_value(double value) { |
485 if (!has_number_value()) { | 588 if (!has_number_value()) { |
486 clear_kind(); | 589 clear_kind(); |
487 set_has_number_value(); | 590 set_has_number_value(); |
488 } | 591 } |
489 kind_.number_value_ = value; | 592 kind_.number_value_ = value; |
490 // @@protoc_insertion_point(field_set:google.protobuf.Value.number_value) | 593 // @@protoc_insertion_point(field_set:google.protobuf.Value.number_value) |
491 } | 594 } |
492 | 595 |
493 // optional string string_value = 3; | 596 // string string_value = 3; |
494 inline bool Value::has_string_value() const { | 597 inline bool Value::has_string_value() const { |
495 return kind_case() == kStringValue; | 598 return kind_case() == kStringValue; |
496 } | 599 } |
497 inline void Value::set_has_string_value() { | 600 inline void Value::set_has_string_value() { |
498 _oneof_case_[0] = kStringValue; | 601 _oneof_case_[0] = kStringValue; |
499 } | 602 } |
500 inline void Value::clear_string_value() { | 603 inline void Value::clear_string_value() { |
501 if (has_string_value()) { | 604 if (has_string_value()) { |
502 kind_.string_value_.DestroyNoArena(&::google::protobuf::internal::GetEmptySt
ringAlreadyInited()); | 605 kind_.string_value_.Destroy(&::google::protobuf::internal::GetEmptyStringAlr
eadyInited(), |
| 606 GetArenaNoVirtual()); |
503 clear_has_kind(); | 607 clear_has_kind(); |
504 } | 608 } |
505 } | 609 } |
506 inline const ::std::string& Value::string_value() const { | 610 inline const ::std::string& Value::string_value() const { |
507 // @@protoc_insertion_point(field_get:google.protobuf.Value.string_value) | 611 // @@protoc_insertion_point(field_get:google.protobuf.Value.string_value) |
508 if (has_string_value()) { | 612 if (has_string_value()) { |
509 return kind_.string_value_.GetNoArena(&::google::protobuf::internal::GetEmpt
yStringAlreadyInited()); | 613 return kind_.string_value_.Get(); |
510 } | 614 } |
511 return *&::google::protobuf::internal::GetEmptyStringAlreadyInited(); | 615 return *&::google::protobuf::internal::GetEmptyStringAlreadyInited(); |
512 } | 616 } |
513 inline void Value::set_string_value(const ::std::string& value) { | 617 inline void Value::set_string_value(const ::std::string& value) { |
514 // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) | |
515 if (!has_string_value()) { | 618 if (!has_string_value()) { |
516 clear_kind(); | 619 clear_kind(); |
517 set_has_string_value(); | 620 set_has_string_value(); |
518 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); | 621 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
519 } | 622 } |
520 kind_.string_value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAl
readyInited(), value); | 623 kind_.string_value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyIn
ited(), value, |
| 624 GetArenaNoVirtual()); |
521 // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) | 625 // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) |
522 } | 626 } |
523 inline void Value::set_string_value(const char* value) { | 627 inline void Value::set_string_value(const char* value) { |
524 if (!has_string_value()) { | 628 if (!has_string_value()) { |
525 clear_kind(); | 629 clear_kind(); |
526 set_has_string_value(); | 630 set_has_string_value(); |
527 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); | 631 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
528 } | 632 } |
529 kind_.string_value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAl
readyInited(), | 633 kind_.string_value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyIn
ited(), |
530 ::std::string(value)); | 634 ::std::string(value), GetArenaNoVirtual()); |
531 // @@protoc_insertion_point(field_set_char:google.protobuf.Value.string_value) | 635 // @@protoc_insertion_point(field_set_char:google.protobuf.Value.string_value) |
532 } | 636 } |
533 inline void Value::set_string_value(const char* value, size_t size) { | 637 inline void Value::set_string_value(const char* value, |
| 638 size_t size) { |
534 if (!has_string_value()) { | 639 if (!has_string_value()) { |
535 clear_kind(); | 640 clear_kind(); |
536 set_has_string_value(); | 641 set_has_string_value(); |
537 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); | 642 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
538 } | 643 } |
539 kind_.string_value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAl
readyInited(), ::std::string( | 644 kind_.string_value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyIn
ited(), ::std::string( |
540 reinterpret_cast<const char*>(value), size)); | 645 reinterpret_cast<const char*>(value), size), |
| 646 GetArenaNoVirtual()); |
541 // @@protoc_insertion_point(field_set_pointer:google.protobuf.Value.string_val
ue) | 647 // @@protoc_insertion_point(field_set_pointer:google.protobuf.Value.string_val
ue) |
542 } | 648 } |
543 inline ::std::string* Value::mutable_string_value() { | 649 inline ::std::string* Value::mutable_string_value() { |
544 if (!has_string_value()) { | 650 if (!has_string_value()) { |
545 clear_kind(); | 651 clear_kind(); |
546 set_has_string_value(); | 652 set_has_string_value(); |
547 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); | 653 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
548 } | 654 } |
| 655 return kind_.string_value_.Mutable(&::google::protobuf::internal::GetEmptyStri
ngAlreadyInited(), |
| 656 GetArenaNoVirtual()); |
549 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.string_value) | 657 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.string_value) |
550 return kind_.string_value_.MutableNoArena(&::google::protobuf::internal::GetEm
ptyStringAlreadyInited()); | |
551 } | 658 } |
552 inline ::std::string* Value::release_string_value() { | 659 inline ::std::string* Value::release_string_value() { |
553 // @@protoc_insertion_point(field_release:google.protobuf.Value.string_value) | 660 // @@protoc_insertion_point(field_release:google.protobuf.Value.string_value) |
554 if (has_string_value()) { | 661 if (has_string_value()) { |
555 clear_has_kind(); | 662 clear_has_kind(); |
556 return kind_.string_value_.ReleaseNoArena(&::google::protobuf::internal::Get
EmptyStringAlreadyInited()); | 663 return kind_.string_value_.Release(&::google::protobuf::internal::GetEmptySt
ringAlreadyInited(), |
| 664 GetArenaNoVirtual()); |
557 } else { | 665 } else { |
558 return NULL; | 666 return NULL; |
559 } | 667 } |
| 668 } |
| 669 inline ::std::string* Value::unsafe_arena_release_string_value() { |
| 670 // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.s
tring_value) |
| 671 GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); |
| 672 if (has_string_value()) { |
| 673 clear_has_kind(); |
| 674 return kind_.string_value_.UnsafeArenaRelease( |
| 675 &::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNo
Virtual()); |
| 676 } else { |
| 677 return NULL; |
| 678 } |
560 } | 679 } |
561 inline void Value::set_allocated_string_value(::std::string* string_value) { | 680 inline void Value::set_allocated_string_value(::std::string* string_value) { |
562 if (!has_string_value()) { | 681 if (!has_string_value()) { |
563 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); | 682 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
564 } | 683 } |
565 clear_kind(); | 684 clear_kind(); |
566 if (string_value != NULL) { | 685 if (string_value != NULL) { |
567 set_has_string_value(); | 686 set_has_string_value(); |
568 kind_.string_value_.SetAllocatedNoArena(&::google::protobuf::internal::GetEm
ptyStringAlreadyInited(), | 687 kind_.string_value_.SetAllocated(&::google::protobuf::internal::GetEmptyStri
ngAlreadyInited(), string_value, |
569 string_value); | 688 GetArenaNoVirtual()); |
570 } | 689 } |
571 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.string_v
alue) | 690 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.string_v
alue) |
572 } | 691 } |
| 692 inline void Value::unsafe_arena_set_allocated_string_value(::std::string* string
_value) { |
| 693 GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); |
| 694 if (!has_string_value()) { |
| 695 kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmpty
StringAlreadyInited()); |
| 696 } |
| 697 clear_kind(); |
| 698 if (string_value) { |
| 699 set_has_string_value(); |
| 700 kind_.string_value_.UnsafeArenaSetAllocated(&::google::protobuf::internal::G
etEmptyStringAlreadyInited(), string_value, GetArenaNoVirtual()); |
| 701 } |
| 702 // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.V
alue.string_value) |
| 703 } |
573 | 704 |
574 // optional bool bool_value = 4; | 705 // bool bool_value = 4; |
575 inline bool Value::has_bool_value() const { | 706 inline bool Value::has_bool_value() const { |
576 return kind_case() == kBoolValue; | 707 return kind_case() == kBoolValue; |
577 } | 708 } |
578 inline void Value::set_has_bool_value() { | 709 inline void Value::set_has_bool_value() { |
579 _oneof_case_[0] = kBoolValue; | 710 _oneof_case_[0] = kBoolValue; |
580 } | 711 } |
581 inline void Value::clear_bool_value() { | 712 inline void Value::clear_bool_value() { |
582 if (has_bool_value()) { | 713 if (has_bool_value()) { |
583 kind_.bool_value_ = false; | 714 kind_.bool_value_ = false; |
584 clear_has_kind(); | 715 clear_has_kind(); |
585 } | 716 } |
586 } | 717 } |
587 inline bool Value::bool_value() const { | 718 inline bool Value::bool_value() const { |
588 // @@protoc_insertion_point(field_get:google.protobuf.Value.bool_value) | 719 // @@protoc_insertion_point(field_get:google.protobuf.Value.bool_value) |
589 if (has_bool_value()) { | 720 if (has_bool_value()) { |
590 return kind_.bool_value_; | 721 return kind_.bool_value_; |
591 } | 722 } |
592 return false; | 723 return false; |
593 } | 724 } |
594 inline void Value::set_bool_value(bool value) { | 725 inline void Value::set_bool_value(bool value) { |
595 if (!has_bool_value()) { | 726 if (!has_bool_value()) { |
596 clear_kind(); | 727 clear_kind(); |
597 set_has_bool_value(); | 728 set_has_bool_value(); |
598 } | 729 } |
599 kind_.bool_value_ = value; | 730 kind_.bool_value_ = value; |
600 // @@protoc_insertion_point(field_set:google.protobuf.Value.bool_value) | 731 // @@protoc_insertion_point(field_set:google.protobuf.Value.bool_value) |
601 } | 732 } |
602 | 733 |
603 // optional .google.protobuf.Struct struct_value = 5; | 734 // .google.protobuf.Struct struct_value = 5; |
604 inline bool Value::has_struct_value() const { | 735 inline bool Value::has_struct_value() const { |
605 return kind_case() == kStructValue; | 736 return kind_case() == kStructValue; |
606 } | 737 } |
607 inline void Value::set_has_struct_value() { | 738 inline void Value::set_has_struct_value() { |
608 _oneof_case_[0] = kStructValue; | 739 _oneof_case_[0] = kStructValue; |
609 } | 740 } |
610 inline void Value::clear_struct_value() { | 741 inline void Value::clear_struct_value() { |
611 if (has_struct_value()) { | 742 if (has_struct_value()) { |
612 delete kind_.struct_value_; | 743 if (GetArenaNoVirtual() == NULL) { |
| 744 delete kind_.struct_value_; |
| 745 } |
613 clear_has_kind(); | 746 clear_has_kind(); |
614 } | 747 } |
615 } | 748 } |
616 inline const ::google::protobuf::Struct& Value::struct_value() const { | 749 inline const ::google::protobuf::Struct& Value::struct_value() const { |
617 // @@protoc_insertion_point(field_get:google.protobuf.Value.struct_value) | 750 // @@protoc_insertion_point(field_get:google.protobuf.Value.struct_value) |
618 return has_struct_value() | 751 return has_struct_value() |
619 ? *kind_.struct_value_ | 752 ? *kind_.struct_value_ |
620 : ::google::protobuf::Struct::default_instance(); | 753 : ::google::protobuf::Struct::default_instance(); |
621 } | 754 } |
622 inline ::google::protobuf::Struct* Value::mutable_struct_value() { | 755 inline ::google::protobuf::Struct* Value::mutable_struct_value() { |
623 if (!has_struct_value()) { | 756 if (!has_struct_value()) { |
624 clear_kind(); | 757 clear_kind(); |
625 set_has_struct_value(); | 758 set_has_struct_value(); |
626 kind_.struct_value_ = new ::google::protobuf::Struct; | 759 kind_.struct_value_ = |
| 760 ::google::protobuf::Arena::CreateMessage< ::google::protobuf::Struct >( |
| 761 GetArenaNoVirtual()); |
627 } | 762 } |
628 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.struct_value) | 763 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.struct_value) |
629 return kind_.struct_value_; | 764 return kind_.struct_value_; |
630 } | 765 } |
631 inline ::google::protobuf::Struct* Value::release_struct_value() { | 766 inline ::google::protobuf::Struct* Value::release_struct_value() { |
632 // @@protoc_insertion_point(field_release:google.protobuf.Value.struct_value) | 767 // @@protoc_insertion_point(field_release:google.protobuf.Value.struct_value) |
633 if (has_struct_value()) { | 768 if (has_struct_value()) { |
634 clear_has_kind(); | 769 clear_has_kind(); |
| 770 if (GetArenaNoVirtual() != NULL) { |
| 771 ::google::protobuf::Struct* temp = new ::google::protobuf::Struct(*kind_.s
truct_value_); |
| 772 kind_.struct_value_ = NULL; |
| 773 return temp; |
| 774 } else { |
| 775 ::google::protobuf::Struct* temp = kind_.struct_value_; |
| 776 kind_.struct_value_ = NULL; |
| 777 return temp; |
| 778 } |
| 779 } else { |
| 780 return NULL; |
| 781 } |
| 782 } |
| 783 inline void Value::set_allocated_struct_value(::google::protobuf::Struct* struct
_value) { |
| 784 clear_kind(); |
| 785 if (struct_value) { |
| 786 if (GetArenaNoVirtual() != NULL && |
| 787 ::google::protobuf::Arena::GetArena(struct_value) == NULL) { |
| 788 GetArenaNoVirtual()->Own(struct_value); |
| 789 } else if (GetArenaNoVirtual() != |
| 790 ::google::protobuf::Arena::GetArena(struct_value)) { |
| 791 ::google::protobuf::Struct* new_struct_value = |
| 792 ::google::protobuf::Arena::CreateMessage< ::google::protobuf::Struct >
( |
| 793 GetArenaNoVirtual()); |
| 794 new_struct_value->CopyFrom(*struct_value); |
| 795 struct_value = new_struct_value; |
| 796 } |
| 797 set_has_struct_value(); |
| 798 kind_.struct_value_ = struct_value; |
| 799 } |
| 800 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.struct_v
alue) |
| 801 } |
| 802 inline ::google::protobuf::Struct* Value::unsafe_arena_release_struct_value() { |
| 803 // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.s
truct_value) |
| 804 if (has_struct_value()) { |
| 805 clear_has_kind(); |
635 ::google::protobuf::Struct* temp = kind_.struct_value_; | 806 ::google::protobuf::Struct* temp = kind_.struct_value_; |
636 kind_.struct_value_ = NULL; | 807 kind_.struct_value_ = NULL; |
637 return temp; | 808 return temp; |
638 } else { | 809 } else { |
639 return NULL; | 810 return NULL; |
640 } | 811 } |
641 } | 812 } |
642 inline void Value::set_allocated_struct_value(::google::protobuf::Struct* struct
_value) { | 813 inline void Value::unsafe_arena_set_allocated_struct_value(::google::protobuf::
Struct* struct_value) { |
643 clear_kind(); | 814 clear_kind(); |
644 if (struct_value) { | 815 if (struct_value) { |
645 set_has_struct_value(); | 816 set_has_struct_value(); |
646 kind_.struct_value_ = struct_value; | 817 kind_.struct_value_ = struct_value; |
647 } | 818 } |
648 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.struct_v
alue) | 819 // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.V
alue.struct_value) |
649 } | 820 } |
650 | 821 |
651 // optional .google.protobuf.ListValue list_value = 6; | 822 // .google.protobuf.ListValue list_value = 6; |
652 inline bool Value::has_list_value() const { | 823 inline bool Value::has_list_value() const { |
653 return kind_case() == kListValue; | 824 return kind_case() == kListValue; |
654 } | 825 } |
655 inline void Value::set_has_list_value() { | 826 inline void Value::set_has_list_value() { |
656 _oneof_case_[0] = kListValue; | 827 _oneof_case_[0] = kListValue; |
657 } | 828 } |
658 inline void Value::clear_list_value() { | 829 inline void Value::clear_list_value() { |
659 if (has_list_value()) { | 830 if (has_list_value()) { |
660 delete kind_.list_value_; | 831 if (GetArenaNoVirtual() == NULL) { |
| 832 delete kind_.list_value_; |
| 833 } |
661 clear_has_kind(); | 834 clear_has_kind(); |
662 } | 835 } |
663 } | 836 } |
664 inline const ::google::protobuf::ListValue& Value::list_value() const { | 837 inline const ::google::protobuf::ListValue& Value::list_value() const { |
665 // @@protoc_insertion_point(field_get:google.protobuf.Value.list_value) | 838 // @@protoc_insertion_point(field_get:google.protobuf.Value.list_value) |
666 return has_list_value() | 839 return has_list_value() |
667 ? *kind_.list_value_ | 840 ? *kind_.list_value_ |
668 : ::google::protobuf::ListValue::default_instance(); | 841 : ::google::protobuf::ListValue::default_instance(); |
669 } | 842 } |
670 inline ::google::protobuf::ListValue* Value::mutable_list_value() { | 843 inline ::google::protobuf::ListValue* Value::mutable_list_value() { |
671 if (!has_list_value()) { | 844 if (!has_list_value()) { |
672 clear_kind(); | 845 clear_kind(); |
673 set_has_list_value(); | 846 set_has_list_value(); |
674 kind_.list_value_ = new ::google::protobuf::ListValue; | 847 kind_.list_value_ = |
| 848 ::google::protobuf::Arena::CreateMessage< ::google::protobuf::ListValue >( |
| 849 GetArenaNoVirtual()); |
675 } | 850 } |
676 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.list_value) | 851 // @@protoc_insertion_point(field_mutable:google.protobuf.Value.list_value) |
677 return kind_.list_value_; | 852 return kind_.list_value_; |
678 } | 853 } |
679 inline ::google::protobuf::ListValue* Value::release_list_value() { | 854 inline ::google::protobuf::ListValue* Value::release_list_value() { |
680 // @@protoc_insertion_point(field_release:google.protobuf.Value.list_value) | 855 // @@protoc_insertion_point(field_release:google.protobuf.Value.list_value) |
681 if (has_list_value()) { | 856 if (has_list_value()) { |
682 clear_has_kind(); | 857 clear_has_kind(); |
| 858 if (GetArenaNoVirtual() != NULL) { |
| 859 ::google::protobuf::ListValue* temp = new ::google::protobuf::ListValue(*k
ind_.list_value_); |
| 860 kind_.list_value_ = NULL; |
| 861 return temp; |
| 862 } else { |
| 863 ::google::protobuf::ListValue* temp = kind_.list_value_; |
| 864 kind_.list_value_ = NULL; |
| 865 return temp; |
| 866 } |
| 867 } else { |
| 868 return NULL; |
| 869 } |
| 870 } |
| 871 inline void Value::set_allocated_list_value(::google::protobuf::ListValue* list_
value) { |
| 872 clear_kind(); |
| 873 if (list_value) { |
| 874 if (GetArenaNoVirtual() != NULL && |
| 875 ::google::protobuf::Arena::GetArena(list_value) == NULL) { |
| 876 GetArenaNoVirtual()->Own(list_value); |
| 877 } else if (GetArenaNoVirtual() != |
| 878 ::google::protobuf::Arena::GetArena(list_value)) { |
| 879 ::google::protobuf::ListValue* new_list_value = |
| 880 ::google::protobuf::Arena::CreateMessage< ::google::protobuf::ListValu
e >( |
| 881 GetArenaNoVirtual()); |
| 882 new_list_value->CopyFrom(*list_value); |
| 883 list_value = new_list_value; |
| 884 } |
| 885 set_has_list_value(); |
| 886 kind_.list_value_ = list_value; |
| 887 } |
| 888 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.list_val
ue) |
| 889 } |
| 890 inline ::google::protobuf::ListValue* Value::unsafe_arena_release_list_value()
{ |
| 891 // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.l
ist_value) |
| 892 if (has_list_value()) { |
| 893 clear_has_kind(); |
683 ::google::protobuf::ListValue* temp = kind_.list_value_; | 894 ::google::protobuf::ListValue* temp = kind_.list_value_; |
684 kind_.list_value_ = NULL; | 895 kind_.list_value_ = NULL; |
685 return temp; | 896 return temp; |
686 } else { | 897 } else { |
687 return NULL; | 898 return NULL; |
688 } | 899 } |
689 } | 900 } |
690 inline void Value::set_allocated_list_value(::google::protobuf::ListValue* list_
value) { | 901 inline void Value::unsafe_arena_set_allocated_list_value(::google::protobuf::Li
stValue* list_value) { |
691 clear_kind(); | 902 clear_kind(); |
692 if (list_value) { | 903 if (list_value) { |
693 set_has_list_value(); | 904 set_has_list_value(); |
694 kind_.list_value_ = list_value; | 905 kind_.list_value_ = list_value; |
695 } | 906 } |
696 // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.list_val
ue) | 907 // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.V
alue.list_value) |
697 } | 908 } |
698 | 909 |
699 inline bool Value::has_kind() const { | 910 inline bool Value::has_kind() const { |
700 return kind_case() != KIND_NOT_SET; | 911 return kind_case() != KIND_NOT_SET; |
701 } | 912 } |
702 inline void Value::clear_has_kind() { | 913 inline void Value::clear_has_kind() { |
703 _oneof_case_[0] = KIND_NOT_SET; | 914 _oneof_case_[0] = KIND_NOT_SET; |
704 } | 915 } |
705 inline Value::KindCase Value::kind_case() const { | 916 inline Value::KindCase Value::kind_case() const { |
706 return Value::KindCase(_oneof_case_[0]); | 917 return Value::KindCase(_oneof_case_[0]); |
(...skipping 30 matching lines...) Expand all Loading... |
737 ListValue::values() const { | 948 ListValue::values() const { |
738 // @@protoc_insertion_point(field_list:google.protobuf.ListValue.values) | 949 // @@protoc_insertion_point(field_list:google.protobuf.ListValue.values) |
739 return values_; | 950 return values_; |
740 } | 951 } |
741 | 952 |
742 #endif // !PROTOBUF_INLINE_NOT_IN_HEADERS | 953 #endif // !PROTOBUF_INLINE_NOT_IN_HEADERS |
743 // ------------------------------------------------------------------- | 954 // ------------------------------------------------------------------- |
744 | 955 |
745 // ------------------------------------------------------------------- | 956 // ------------------------------------------------------------------- |
746 | 957 |
| 958 // ------------------------------------------------------------------- |
| 959 |
747 | 960 |
748 // @@protoc_insertion_point(namespace_scope) | 961 // @@protoc_insertion_point(namespace_scope) |
749 | 962 |
| 963 |
750 } // namespace protobuf | 964 } // namespace protobuf |
751 } // namespace google | 965 } // namespace google |
752 | 966 |
753 #ifndef SWIG | 967 #ifndef SWIG |
754 namespace google { | 968 namespace google { |
755 namespace protobuf { | 969 namespace protobuf { |
756 | 970 |
757 template <> struct is_proto_enum< ::google::protobuf::NullValue> : ::google::pro
tobuf::internal::true_type {}; | 971 template <> struct is_proto_enum< ::google::protobuf::NullValue> : ::google::pro
tobuf::internal::true_type {}; |
758 template <> | 972 template <> |
759 inline const EnumDescriptor* GetEnumDescriptor< ::google::protobuf::NullValue>()
{ | 973 inline const EnumDescriptor* GetEnumDescriptor< ::google::protobuf::NullValue>()
{ |
760 return ::google::protobuf::NullValue_descriptor(); | 974 return ::google::protobuf::NullValue_descriptor(); |
761 } | 975 } |
762 | 976 |
763 } // namespace protobuf | 977 } // namespace protobuf |
764 } // namespace google | 978 } // namespace google |
765 #endif // SWIG | 979 #endif // SWIG |
766 | 980 |
767 // @@protoc_insertion_point(global_scope) | 981 // @@protoc_insertion_point(global_scope) |
768 | 982 |
769 #endif // PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED | 983 #endif // PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED |
OLD | NEW |