diff options
author | Michael Lehenbauer <mikelehen@gmail.com> | 2018-04-12 09:08:18 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-12 09:08:18 -0700 |
commit | 6f2ef7d3899f05dae7eb03847d8dddf9b04a7738 (patch) | |
tree | 690f179be9097ed3df9bfeb5ddb59ebcc1ab6299 /Firestore/Protos/objc/google/api/HTTP.pbobjc.h | |
parent | 74411e5739237e70fd62c8364626c17ec37ed595 (diff) |
Update protos. (#1075)
Diffstat (limited to 'Firestore/Protos/objc/google/api/HTTP.pbobjc.h')
-rw-r--r-- | Firestore/Protos/objc/google/api/HTTP.pbobjc.h | 75 |
1 files changed, 51 insertions, 24 deletions
diff --git a/Firestore/Protos/objc/google/api/HTTP.pbobjc.h b/Firestore/Protos/objc/google/api/HTTP.pbobjc.h index 9cc00dc..c9e5bb5 100644 --- a/Firestore/Protos/objc/google/api/HTTP.pbobjc.h +++ b/Firestore/Protos/objc/google/api/HTTP.pbobjc.h @@ -67,10 +67,11 @@ NS_ASSUME_NONNULL_BEGIN typedef GPB_ENUM(GAPIHttp_FieldNumber) { GAPIHttp_FieldNumber_RulesArray = 1, + GAPIHttp_FieldNumber_FullyDecodeReservedExpansion = 2, }; /** - * Defines the HTTP configuration for a service. It contains a list of + * Defines the HTTP configuration for an API service. It contains a list of * [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method * to one or more HTTP REST API methods. **/ @@ -85,6 +86,16 @@ typedef GPB_ENUM(GAPIHttp_FieldNumber) { /** The number of items in @c rulesArray without causing the array to be created. */ @property(nonatomic, readonly) NSUInteger rulesArray_Count; +/** + * When set to true, URL path parmeters will be fully URI-decoded except in + * cases of single segment matches in reserved expansion, where "%2F" will be + * left encoded. + * + * The default behavior is to not decode RFC 6570 reserved characters in multi + * segment matches. + **/ +@property(nonatomic, readwrite) BOOL fullyDecodeReservedExpansion; + @end #pragma mark - GAPIHttpRule @@ -113,11 +124,11 @@ typedef GPB_ENUM(GAPIHttpRule_Pattern_OneOfCase) { /** * `HttpRule` defines the mapping of an RPC method to one or more HTTP - * REST APIs. The mapping determines what portions of the request - * message are populated from the path, query parameters, or body of - * the HTTP request. The mapping is typically specified as an - * `google.api.http` annotation, see "google/api/annotations.proto" - * for details. + * REST API methods. The mapping specifies how different portions of the RPC + * request message are mapped to URL path, URL query parameters, and + * HTTP request body. The mapping is typically specified as an + * `google.api.http` annotation on the RPC method, + * see "google/api/annotations.proto" for details. * * The mapping consists of a field specifying the path template and * method kind. The path template can refer to fields in the request @@ -165,6 +176,11 @@ typedef GPB_ENUM(GAPIHttpRule_Pattern_OneOfCase) { * parameters. Assume the following definition of the request message: * * + * service Messaging { + * rpc GetMessage(GetMessageRequest) returns (Message) { + * option (google.api.http).get = "/v1/messages/{message_id}"; + * } + * } * message GetMessageRequest { * message SubMessage { * string subfield = 1; @@ -277,7 +293,7 @@ typedef GPB_ENUM(GAPIHttpRule_Pattern_OneOfCase) { * to the request message are as follows: * * 1. The `body` field specifies either `*` or a field path, or is - * omitted. If omitted, it assumes there is no HTTP body. + * omitted. If omitted, it indicates there is no HTTP request body. * 2. Leaf fields (recursive expansion of nested messages in the * request) can be classified into three types: * (a) Matched in the URL template. @@ -296,28 +312,34 @@ typedef GPB_ENUM(GAPIHttpRule_Pattern_OneOfCase) { * FieldPath = IDENT { "." IDENT } ; * Verb = ":" LITERAL ; * - * The syntax `*` matches a single path segment. It follows the semantics of - * [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String - * Expansion. + * The syntax `*` matches a single path segment. The syntax `**` matches zero + * or more path segments, which must be the last part of the path except the + * `Verb`. The syntax `LITERAL` matches literal text in the path. * - * The syntax `**` matches zero or more path segments. It follows the semantics - * of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.3 Reserved - * Expansion. NOTE: it must be the last segment in the path except the Verb. - * - * The syntax `LITERAL` matches literal text in the URL path. - * - * The syntax `Variable` matches the entire path as specified by its template; - * this nested template must not contain further variables. If a variable + * The syntax `Variable` matches part of the URL path as specified by its + * template. A variable template must not contain other variables. If a variable * matches a single path segment, its template may be omitted, e.g. `{var}` * is equivalent to `{var=*}`. * + * If a variable contains exactly one path segment, such as `"{var}"` or + * `"{var=*}"`, when such a variable is expanded into a URL path, all characters + * except `[-_.~0-9a-zA-Z]` are percent-encoded. Such variables show up in the + * Discovery Document as `{var}`. + * + * If a variable contains one or more path segments, such as `"{var=foo/\*}"` + * or `"{var=**}"`, when such a variable is expanded into a URL path, all + * characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. Such variables + * show up in the Discovery Document as `{+var}`. + * + * NOTE: While the single segment variable matches the semantics of + * [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 + * Simple String Expansion, the multi segment variable **does not** match + * RFC 6570 Reserved Expansion. The reason is that the Reserved Expansion + * does not expand special characters like `?` and `#`, which would lead + * to invalid URLs. + * * NOTE: the field paths in variables and in the `body` must not refer to * repeated fields or map fields. - * - * Use CustomHttpPattern to specify any HTTP method that is not included in the - * `pattern` field, such as HEAD, or "*" to leave the HTTP method unspecified for - * a given URL path rule. The wild-card rule is useful for services that provide - * content to Web (HTML) clients. **/ @interface GAPIHttpRule : GPBMessage @@ -350,7 +372,12 @@ typedef GPB_ENUM(GAPIHttpRule_Pattern_OneOfCase) { /** Used for updating a resource. */ @property(nonatomic, readwrite, copy, null_resettable) NSString *patch; -/** Custom pattern is used for defining custom verbs. */ +/** + * The custom pattern is used for specifying an HTTP method that is not + * included in the `pattern` field, such as HEAD, or "*" to leave the + * HTTP method unspecified for this rule. The wild-card rule is useful + * for services that provide content to Web (HTML) clients. + **/ @property(nonatomic, readwrite, strong, null_resettable) GAPICustomHttpPattern *custom; /** |