1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // NO CHECKED-IN PROTOBUF GENCODE
4 // source: google/protobuf/api.proto
6 #import "GPBDescriptor.h"
8 #import "GPBRootObject.h"
9 #import "GPBSourceContext.pbobjc.h"
10 #import "GPBType.pbobjc.h"
12 #if GOOGLE_PROTOBUF_OBJC_VERSION < 30007
13 #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources.
15 #if 30007 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION
16 #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources.
19 // @@protoc_insertion_point(imports)
21 #pragma clang diagnostic push
22 #pragma clang diagnostic ignored "-Wdeprecated-declarations"
29 NS_ASSUME_NONNULL_BEGIN
31 #pragma mark - GPBApiRoot
34 * Exposes the extension registry for this file.
36 * The base class provides:
38 * + (GPBExtensionRegistry *)extensionRegistry;
40 * which is a @c GPBExtensionRegistry that includes all the extensions defined by
41 * this file and all files that it depends on.
43 GPB_FINAL @interface GPBApiRoot
: GPBRootObject
48 typedef GPB_ENUM(GPBApi_FieldNumber
) {
49 GPBApi_FieldNumber_Name
= 1,
50 GPBApi_FieldNumber_MethodsArray
= 2,
51 GPBApi_FieldNumber_OptionsArray
= 3,
52 GPBApi_FieldNumber_Version
= 4,
53 GPBApi_FieldNumber_SourceContext
= 5,
54 GPBApi_FieldNumber_MixinsArray
= 6,
55 GPBApi_FieldNumber_Syntax
= 7,
59 * Api is a light-weight descriptor for an API Interface.
61 * Interfaces are also described as "protocol buffer services" in some contexts,
62 * such as by the "service" keyword in a .proto file, but they are different
63 * from API Services, which represent a concrete implementation of an interface
64 * as opposed to simply a description of methods and bindings. They are also
65 * sometimes simply referred to as "APIs" in other contexts, such as the name of
66 * this message itself. See https://cloud.google.com/apis/design/glossary for
67 * detailed terminology.
69 GPB_FINAL @interface GPBApi
: GPBMessage
72 * The fully qualified name of this interface, including package name
73 * followed by the interface's simple name.
75 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*name
;
77 /** The methods of this interface, in unspecified order. */
78 @
property(nonatomic
, readwrite
, strong
, null_resettable
) NSMutableArray
<GPBMethod
*> *methodsArray
;
79 /** The number of items in @c methodsArray without causing the container to be created. */
80 @
property(nonatomic
, readonly
) NSUInteger methodsArray_Count
;
82 /** Any metadata attached to the interface. */
83 @
property(nonatomic
, readwrite
, strong
, null_resettable
) NSMutableArray
<GPBOption
*> *optionsArray
;
84 /** The number of items in @c optionsArray without causing the container to be created. */
85 @
property(nonatomic
, readonly
) NSUInteger optionsArray_Count
;
88 * A version string for this interface. If specified, must have the form
89 * `major-version.minor-version`, as in `1.10`. If the minor version is
90 * omitted, it defaults to zero. If the entire version field is empty, the
91 * major version is derived from the package name, as outlined below. If the
92 * field is not empty, the version in the package name will be verified to be
93 * consistent with what is provided here.
95 * The versioning schema uses [semantic
96 * versioning](http://semver.org) where the major version number
97 * indicates a breaking change and the minor version an additive,
98 * non-breaking change. Both version numbers are signals to users
99 * what to expect from different versions, and should be carefully
100 * chosen based on the product plan.
102 * The major version is also reflected in the package name of the
103 * interface, which must end in `v<major-version>`, as in
104 * `google.feature.v1`. For major versions 0 and 1, the suffix can
105 * be omitted. Zero major versions must only be used for
106 * experimental, non-GA interfaces.
108 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*version
;
111 * Source context for the protocol buffer service represented by this
114 @
property(nonatomic
, readwrite
, strong
, null_resettable
) GPBSourceContext
*sourceContext
;
115 /** Test to see if @c sourceContext has been set. */
116 @
property(nonatomic
, readwrite
) BOOL hasSourceContext
;
118 /** Included interfaces. See [Mixin][]. */
119 @
property(nonatomic
, readwrite
, strong
, null_resettable
) NSMutableArray
<GPBMixin
*> *mixinsArray
;
120 /** The number of items in @c mixinsArray without causing the container to be created. */
121 @
property(nonatomic
, readonly
) NSUInteger mixinsArray_Count
;
123 /** The source syntax of the service. */
124 @
property(nonatomic
, readwrite
) GPBSyntax syntax
;
129 * Fetches the raw value of a @c GPBApi's @c syntax property, even
130 * if the value was not defined by the enum at the time the code was generated.
132 int32_t GPBApi_Syntax_RawValue(GPBApi
*message
);
134 * Sets the raw value of an @c GPBApi's @c syntax property, allowing
135 * it to be set to a value that was not defined by the enum at the time the code
138 void SetGPBApi_Syntax_RawValue(GPBApi
*message
, int32_t value
);
140 #pragma mark - GPBMethod
142 typedef GPB_ENUM(GPBMethod_FieldNumber
) {
143 GPBMethod_FieldNumber_Name
= 1,
144 GPBMethod_FieldNumber_RequestTypeURL
= 2,
145 GPBMethod_FieldNumber_RequestStreaming
= 3,
146 GPBMethod_FieldNumber_ResponseTypeURL
= 4,
147 GPBMethod_FieldNumber_ResponseStreaming
= 5,
148 GPBMethod_FieldNumber_OptionsArray
= 6,
149 GPBMethod_FieldNumber_Syntax
= 7,
153 * Method represents a method of an API interface.
155 GPB_FINAL @interface GPBMethod
: GPBMessage
157 /** The simple name of this method. */
158 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*name
;
160 /** A URL of the input message type. */
161 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*requestTypeURL
;
163 /** If true, the request is streamed. */
164 @
property(nonatomic
, readwrite
) BOOL requestStreaming
;
166 /** The URL of the output message type. */
167 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*responseTypeURL
;
169 /** If true, the response is streamed. */
170 @
property(nonatomic
, readwrite
) BOOL responseStreaming
;
172 /** Any metadata attached to the method. */
173 @
property(nonatomic
, readwrite
, strong
, null_resettable
) NSMutableArray
<GPBOption
*> *optionsArray
;
174 /** The number of items in @c optionsArray without causing the container to be created. */
175 @
property(nonatomic
, readonly
) NSUInteger optionsArray_Count
;
177 /** The source syntax of this method. */
178 @
property(nonatomic
, readwrite
) GPBSyntax syntax
;
183 * Fetches the raw value of a @c GPBMethod's @c syntax property, even
184 * if the value was not defined by the enum at the time the code was generated.
186 int32_t GPBMethod_Syntax_RawValue(GPBMethod
*message
);
188 * Sets the raw value of an @c GPBMethod's @c syntax property, allowing
189 * it to be set to a value that was not defined by the enum at the time the code
192 void SetGPBMethod_Syntax_RawValue(GPBMethod
*message
, int32_t value
);
194 #pragma mark - GPBMixin
196 typedef GPB_ENUM(GPBMixin_FieldNumber
) {
197 GPBMixin_FieldNumber_Name
= 1,
198 GPBMixin_FieldNumber_Root
= 2,
202 * Declares an API Interface to be included in this interface. The including
203 * interface must redeclare all the methods from the included interface, but
204 * documentation and options are inherited as follows:
206 * - If after comment and whitespace stripping, the documentation
207 * string of the redeclared method is empty, it will be inherited
208 * from the original method.
210 * - Each annotation belonging to the service config (http,
211 * visibility) which is not set in the redeclared method will be
214 * - If an http annotation is inherited, the path pattern will be
215 * modified as follows. Any version prefix will be replaced by the
216 * version of the including interface plus the [root][] path if
219 * Example of a simple mixin:
221 * package google.acl.v1;
222 * service AccessControl {
223 * // Get the underlying ACL object.
224 * rpc GetAcl(GetAclRequest) returns (Acl) {
225 * option (google.api.http).get = "/v1/{resource=**}:getAcl";
229 * package google.storage.v2;
231 * rpc GetAcl(GetAclRequest) returns (Acl);
233 * // Get a data record.
234 * rpc GetData(GetDataRequest) returns (Data) {
235 * option (google.api.http).get = "/v2/{resource=**}";
239 * Example of a mixin configuration:
242 * - name: google.storage.v2.Storage
244 * - name: google.acl.v1.AccessControl
246 * The mixin construct implies that all methods in `AccessControl` are
247 * also declared with same name and request/response types in
248 * `Storage`. A documentation generator or annotation processor will
249 * see the effective `Storage.GetAcl` method after inheriting
250 * documentation and annotations as follows:
253 * // Get the underlying ACL object.
254 * rpc GetAcl(GetAclRequest) returns (Acl) {
255 * option (google.api.http).get = "/v2/{resource=**}:getAcl";
260 * Note how the version in the path pattern changed from `v1` to `v2`.
262 * If the `root` field in the mixin is specified, it should be a
263 * relative path under which inherited HTTP paths are placed. Example:
266 * - name: google.storage.v2.Storage
268 * - name: google.acl.v1.AccessControl
271 * This implies the following inherited HTTP annotation:
274 * // Get the underlying ACL object.
275 * rpc GetAcl(GetAclRequest) returns (Acl) {
276 * option (google.api.http).get = "/v2/acls/{resource=**}:getAcl";
281 GPB_FINAL @interface GPBMixin
: GPBMessage
283 /** The fully qualified name of the interface which is included. */
284 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*name
;
287 * If non-empty specifies a path under which inherited HTTP paths
290 @
property(nonatomic
, readwrite
, copy
, null_resettable
) NSString
*root
;
294 NS_ASSUME_NONNULL_END
298 #pragma clang diagnostic pop
300 // @@protoc_insertion_point(global_scope)