diff --git a/examples/internal/clients/abe/api/swagger.yaml b/examples/internal/clients/abe/api/swagger.yaml index 80a0ea203e2..a2686cf2b83 100644 --- a/examples/internal/clients/abe/api/swagger.yaml +++ b/examples/internal/clients/abe/api/swagger.yaml @@ -1864,11 +1864,9 @@ paths: in: "query" description: "The paths to update." required: false - type: "array" - items: - type: "string" - collectionFormat: "multi" + type: "string" x-exportParamName: "UpdateMask" + x-optionalDataType: "String" responses: 200: description: "A successful response." @@ -1910,11 +1908,9 @@ paths: in: "query" description: "The paths to update." required: false - type: "array" - items: - type: "string" - collectionFormat: "multi" + type: "string" x-exportParamName: "UpdateMask" + x-optionalDataType: "String" responses: 200: description: "A successful response." @@ -2620,10 +2616,8 @@ definitions: abe: $ref: "#/definitions/examplepbABitOfEverything" updateMask: - type: "array" + type: "string" description: "The paths to update." - items: - type: "string" title: "UpdateV2Request request for update includes the message and the update\ \ mask" pathenumPathEnum: diff --git a/examples/internal/clients/abe/api_a_bit_of_everything_service.go b/examples/internal/clients/abe/api_a_bit_of_everything_service.go index c51a3ab96ad..45aaffd3dec 100644 --- a/examples/internal/clients/abe/api_a_bit_of_everything_service.go +++ b/examples/internal/clients/abe/api_a_bit_of_everything_service.go @@ -3554,13 +3554,13 @@ ABitOfEverythingServiceApiService * @param abeUuid * @param body * @param optional nil or *ABitOfEverythingServiceUpdateV2Opts - Optional Parameters: - * @param "UpdateMask" (optional.Interface of []string) - The paths to update. + * @param "UpdateMask" (optional.String) - The paths to update. @return interface{} */ type ABitOfEverythingServiceUpdateV2Opts struct { - UpdateMask optional.Interface + UpdateMask optional.String } func (a *ABitOfEverythingServiceApiService) ABitOfEverythingServiceUpdateV2(ctx context.Context, abeUuid string, body ExamplepbABitOfEverything, localVarOptionals *ABitOfEverythingServiceUpdateV2Opts) (interface{}, *http.Response, error) { @@ -3581,7 +3581,7 @@ func (a *ABitOfEverythingServiceApiService) ABitOfEverythingServiceUpdateV2(ctx localVarFormParams := url.Values{} if localVarOptionals != nil && localVarOptionals.UpdateMask.IsSet() { - localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "multi")) + localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "")) } // to determine the Content-Type header localVarHttpContentTypes := []string{"application/json", "application/x-foo-mime"} @@ -3712,13 +3712,13 @@ ABitOfEverythingServiceApiService * @param abeUuid * @param body * @param optional nil or *ABitOfEverythingServiceUpdateV22Opts - Optional Parameters: - * @param "UpdateMask" (optional.Interface of []string) - The paths to update. + * @param "UpdateMask" (optional.String) - The paths to update. @return interface{} */ type ABitOfEverythingServiceUpdateV22Opts struct { - UpdateMask optional.Interface + UpdateMask optional.String } func (a *ABitOfEverythingServiceApiService) ABitOfEverythingServiceUpdateV22(ctx context.Context, abeUuid string, body ExamplepbABitOfEverything, localVarOptionals *ABitOfEverythingServiceUpdateV22Opts) (interface{}, *http.Response, error) { @@ -3739,7 +3739,7 @@ func (a *ABitOfEverythingServiceApiService) ABitOfEverythingServiceUpdateV22(ctx localVarFormParams := url.Values{} if localVarOptionals != nil && localVarOptionals.UpdateMask.IsSet() { - localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "multi")) + localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "")) } // to determine the Content-Type header localVarHttpContentTypes := []string{"application/json", "application/x-foo-mime"} diff --git a/examples/internal/clients/abe/model_examplepb_update_v2_request.go b/examples/internal/clients/abe/model_examplepb_update_v2_request.go index 2c867a542d0..dab839628b5 100644 --- a/examples/internal/clients/abe/model_examplepb_update_v2_request.go +++ b/examples/internal/clients/abe/model_examplepb_update_v2_request.go @@ -13,5 +13,5 @@ package abe type ExamplepbUpdateV2Request struct { Abe *ExamplepbABitOfEverything `json:"abe,omitempty"` // The paths to update. - UpdateMask []string `json:"updateMask,omitempty"` + UpdateMask string `json:"updateMask,omitempty"` } diff --git a/examples/internal/clients/echo/api/swagger.yaml b/examples/internal/clients/echo/api/swagger.yaml index c4221e8b272..cbda5f0f24b 100644 --- a/examples/internal/clients/echo/api/swagger.yaml +++ b/examples/internal/clients/echo/api/swagger.yaml @@ -433,11 +433,9 @@ paths: - name: "updateMask" in: "query" required: false - type: "array" - items: - type: "string" - collectionFormat: "multi" + type: "string" x-exportParamName: "UpdateMask" + x-optionalDataType: "String" responses: 200: description: "A successful response." @@ -468,16 +466,12 @@ definitions: body: $ref: "#/definitions/examplepbDynamicMessage" updateMask: - type: "array" - items: - type: "string" + type: "string" example: body: structField: "{}" valueField: "{}" - updateMask: - - "updateMask" - - "updateMask" + updateMask: "updateMask" examplepbEmbedded: type: "object" properties: diff --git a/examples/internal/clients/echo/api_echo_service.go b/examples/internal/clients/echo/api_echo_service.go index 0944bc92be4..1bcf461f765 100644 --- a/examples/internal/clients/echo/api_echo_service.go +++ b/examples/internal/clients/echo/api_echo_service.go @@ -933,13 +933,13 @@ EchoServiceApiService EchoPatch method receives a NonStandardUpdateRequest and r * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param body * @param optional nil or *EchoServiceEchoPatchOpts - Optional Parameters: - * @param "UpdateMask" (optional.Interface of []string) - + * @param "UpdateMask" (optional.String) - @return ExamplepbDynamicMessageUpdate */ type EchoServiceEchoPatchOpts struct { - UpdateMask optional.Interface + UpdateMask optional.String } func (a *EchoServiceApiService) EchoServiceEchoPatch(ctx context.Context, body ExamplepbDynamicMessage, localVarOptionals *EchoServiceEchoPatchOpts) (ExamplepbDynamicMessageUpdate, *http.Response, error) { @@ -959,7 +959,7 @@ func (a *EchoServiceApiService) EchoServiceEchoPatch(ctx context.Context, body E localVarFormParams := url.Values{} if localVarOptionals != nil && localVarOptionals.UpdateMask.IsSet() { - localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "multi")) + localVarQueryParams.Add("updateMask", parameterToString(localVarOptionals.UpdateMask.Value(), "")) } // to determine the Content-Type header localVarHttpContentTypes := []string{"application/json"} diff --git a/examples/internal/clients/echo/model_examplepb_dynamic_message_update.go b/examples/internal/clients/echo/model_examplepb_dynamic_message_update.go index cc7fb56195c..086ab7c045e 100644 --- a/examples/internal/clients/echo/model_examplepb_dynamic_message_update.go +++ b/examples/internal/clients/echo/model_examplepb_dynamic_message_update.go @@ -11,5 +11,5 @@ package echo type ExamplepbDynamicMessageUpdate struct { Body *ExamplepbDynamicMessage `json:"body,omitempty"` - UpdateMask []string `json:"updateMask,omitempty"` + UpdateMask string `json:"updateMask,omitempty"` } diff --git a/examples/internal/proto/examplepb/a_bit_of_everything.swagger.json b/examples/internal/proto/examplepb/a_bit_of_everything.swagger.json index ede085b3308..148388b083f 100644 --- a/examples/internal/proto/examplepb/a_bit_of_everything.swagger.json +++ b/examples/internal/proto/examplepb/a_bit_of_everything.swagger.json @@ -2208,11 +2208,7 @@ "description": "The paths to update.", "in": "query", "required": false, - "type": "array", - "items": { - "type": "string" - }, - "collectionFormat": "multi" + "type": "string" } ], "tags": [ @@ -2272,11 +2268,7 @@ "description": "The paths to update.", "in": "query", "required": false, - "type": "array", - "items": { - "type": "string" - }, - "collectionFormat": "multi" + "type": "string" } ], "tags": [ @@ -3194,10 +3186,7 @@ "$ref": "#/definitions/examplepbABitOfEverything" }, "updateMask": { - "type": "array", - "items": { - "type": "string" - }, + "type": "string", "description": "The paths to update." } }, diff --git a/examples/internal/proto/examplepb/echo_service.swagger.json b/examples/internal/proto/examplepb/echo_service.swagger.json index 501cfc86152..80deb2a9a29 100644 --- a/examples/internal/proto/examplepb/echo_service.swagger.json +++ b/examples/internal/proto/examplepb/echo_service.swagger.json @@ -526,11 +526,7 @@ "name": "updateMask", "in": "query", "required": false, - "type": "array", - "items": { - "type": "string" - }, - "collectionFormat": "multi" + "type": "string" } ], "tags": [ @@ -559,10 +555,7 @@ "$ref": "#/definitions/examplepbDynamicMessage" }, "updateMask": { - "type": "array", - "items": { - "type": "string" - } + "type": "string" } } },