1 // Generated by the protocol buffer compiler.  DO NOT EDIT!
2 // source: google/protobuf/struct.proto
3 
4 // This CPP symbol can be defined to use imports that match up to the framework
5 // imports needed when using CocoaPods.
6 #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS)
7  #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0
8 #endif
9 
10 #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS
11  #import <Protobuf/GPBProtocolBuffers.h>
12 #else
13  #import "GPBProtocolBuffers.h"
14 #endif
15 
16 #if GOOGLE_PROTOBUF_OBJC_GEN_VERSION != 30001
17 #error This file was generated by a different version of protoc which is incompatible with your Protocol Buffer library sources.
18 #endif
19 
20 // @@protoc_insertion_point(imports)
21 
22 #pragma clang diagnostic push
23 #pragma clang diagnostic ignored "-Wdeprecated-declarations"
24 
25 CF_EXTERN_C_BEGIN
26 
27 @class GPBListValue;
28 @class GPBStruct;
29 @class GPBValue;
30 
31 NS_ASSUME_NONNULL_BEGIN
32 
33 #pragma mark - Enum GPBNullValue
34 
35 /// `NullValue` is a singleton enumeration to represent the null value for the
36 /// `Value` type union.
37 ///
38 ///  The JSON representation for `NullValue` is JSON `null`.
39 typedef GPB_ENUM(GPBNullValue) {
40   /// Value used if any message's field encounters a value that is not defined
41   /// by this enum. The message will also have C functions to get/set the rawValue
42   /// of the field.
43   GPBNullValue_GPBUnrecognizedEnumeratorValue = kGPBUnrecognizedEnumeratorValue,
44   /// Null value.
45   GPBNullValue_NullValue = 0,
46 };
47 
48 GPBEnumDescriptor *GPBNullValue_EnumDescriptor(void);
49 
50 /// Checks to see if the given value is defined by the enum or was not known at
51 /// the time this source was generated.
52 BOOL GPBNullValue_IsValidValue(int32_t value);
53 
54 #pragma mark - GPBStructRoot
55 
56 /// Exposes the extension registry for this file.
57 ///
58 /// The base class provides:
59 /// @code
60 ///   + (GPBExtensionRegistry *)extensionRegistry;
61 /// @endcode
62 /// which is a @c GPBExtensionRegistry that includes all the extensions defined by
63 /// this file and all files that it depends on.
64 @interface GPBStructRoot : GPBRootObject
65 @end
66 
67 #pragma mark - GPBStruct
68 
69 typedef GPB_ENUM(GPBStruct_FieldNumber) {
70   GPBStruct_FieldNumber_Fields = 1,
71 };
72 
73 /// `Struct` represents a structured data value, consisting of fields
74 /// which map to dynamically typed values. In some languages, `Struct`
75 /// might be supported by a native representation. For example, in
76 /// scripting languages like JS a struct is represented as an
77 /// object. The details of that representation are described together
78 /// with the proto support for the language.
79 ///
80 /// The JSON representation for `Struct` is JSON object.
81 @interface GPBStruct : GPBMessage
82 
83 /// Unordered map of dynamically typed values.
84 @property(nonatomic, readwrite, strong, null_resettable) NSMutableDictionary<NSString*, GPBValue*> *fields;
85 /// The number of items in @c fields without causing the array to be created.
property(nonatomic,readonly)86 @property(nonatomic, readonly) NSUInteger fields_Count;
87 
88 @end
89 
90 #pragma mark - GPBValue
91 
92 typedef GPB_ENUM(GPBValue_FieldNumber) {
93   GPBValue_FieldNumber_NullValue = 1,
94   GPBValue_FieldNumber_NumberValue = 2,
95   GPBValue_FieldNumber_StringValue = 3,
96   GPBValue_FieldNumber_BoolValue = 4,
97   GPBValue_FieldNumber_StructValue = 5,
98   GPBValue_FieldNumber_ListValue = 6,
99 };
100 
101 typedef GPB_ENUM(GPBValue_Kind_OneOfCase) {
102   GPBValue_Kind_OneOfCase_GPBUnsetOneOfCase = 0,
103   GPBValue_Kind_OneOfCase_NullValue = 1,
104   GPBValue_Kind_OneOfCase_NumberValue = 2,
105   GPBValue_Kind_OneOfCase_StringValue = 3,
106   GPBValue_Kind_OneOfCase_BoolValue = 4,
107   GPBValue_Kind_OneOfCase_StructValue = 5,
108   GPBValue_Kind_OneOfCase_ListValue = 6,
109 };
110 
111 /// `Value` represents a dynamically typed value which can be either
112 /// null, a number, a string, a boolean, a recursive struct value, or a
113 /// list of values. A producer of value is expected to set one of that
114 /// variants, absence of any variant indicates an error.
115 ///
116 /// The JSON representation for `Value` is JSON value.
117 @interface GPBValue : GPBMessage
118 
119 /// The kind of value.
120 @property(nonatomic, readonly) GPBValue_Kind_OneOfCase kindOneOfCase;
121 
122 /// Represents a null value.
123 @property(nonatomic, readwrite) GPBNullValue nullValue;
124 
125 /// Represents a double value.
126 @property(nonatomic, readwrite) double numberValue;
127 
128 /// Represents a string value.
129 @property(nonatomic, readwrite, copy, null_resettable) NSString *stringValue;
130 
131 /// Represents a boolean value.
132 @property(nonatomic, readwrite) BOOL boolValue;
133 
134 /// Represents a structured value.
135 @property(nonatomic, readwrite, strong, null_resettable) GPBStruct *structValue;
136 
137 /// Represents a repeated `Value`.
138 @property(nonatomic, readwrite, strong, null_resettable) GPBListValue *listValue;
139 
140 @end
141 
142 /// Fetches the raw value of a @c GPBValue's @c nullValue property, even
143 /// if the value was not defined by the enum at the time the code was generated.
144 int32_t GPBValue_NullValue_RawValue(GPBValue *message);
145 /// Sets the raw value of an @c GPBValue's @c nullValue property, allowing
146 /// it to be set to a value that was not defined by the enum at the time the code
147 /// was generated.
148 void SetGPBValue_NullValue_RawValue(GPBValue *message, int32_t value);
149 
150 /// Clears whatever value was set for the oneof 'kind'.
151 void GPBValue_ClearKindOneOfCase(GPBValue *message);
152 
153 #pragma mark - GPBListValue
154 
155 typedef GPB_ENUM(GPBListValue_FieldNumber) {
156   GPBListValue_FieldNumber_ValuesArray = 1,
157 };
158 
159 /// `ListValue` is a wrapper around a repeated field of values.
160 ///
161 /// The JSON representation for `ListValue` is JSON array.
162 @interface GPBListValue : GPBMessage
163 
164 /// Repeated field of dynamically typed values.
165 @property(nonatomic, readwrite, strong, null_resettable) NSMutableArray<GPBValue*> *valuesArray;
166 /// The number of items in @c valuesArray without causing the array to be created.
167 @property(nonatomic, readonly) NSUInteger valuesArray_Count;
168 
169 @end
170 
171 NS_ASSUME_NONNULL_END
172 
173 CF_EXTERN_C_END
174 
175 #pragma clang diagnostic pop
176 
177 // @@protoc_insertion_point(global_scope)
178