Skip to content

Commit 0664a1c

Browse files
feat: Automated regeneration of Forms client (googleapis#12568)
Auto-created at 2024-11-19 13:15:50 +0000 using the toys pull request generator.
1 parent b9857a9 commit 0664a1c

File tree

5 files changed

+55
-3
lines changed

5 files changed

+55
-3
lines changed

clients/forms/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding
1111

1212
```elixir
1313
def deps do
14-
[{:google_api_forms, "~> 0.3"}]
14+
[{:google_api_forms, "~> 0.4"}]
1515
end
1616
```
1717

clients/forms/lib/google_api/forms/v1/metadata.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ defmodule GoogleApi.Forms.V1 do
2020
API client metadata for GoogleApi.Forms.V1.
2121
"""
2222

23-
@discovery_revision "20220908"
23+
@discovery_revision "20241112"
2424

2525
def discovery_revision(), do: @discovery_revision
2626
end

clients/forms/lib/google_api/forms/v1/model/question.ex

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ defmodule GoogleApi.Forms.V1.Model.Question do
2626
* `fileUploadQuestion` (*type:* `GoogleApi.Forms.V1.Model.FileUploadQuestion.t`, *default:* `nil`) - A respondent can upload one or more files.
2727
* `grading` (*type:* `GoogleApi.Forms.V1.Model.Grading.t`, *default:* `nil`) - Grading setup for the question.
2828
* `questionId` (*type:* `String.t`, *default:* `nil`) - Read only. The question ID. On creation, it can be provided but the ID must not be already used in the form. If not provided, a new ID is assigned.
29+
* `ratingQuestion` (*type:* `GoogleApi.Forms.V1.Model.RatingQuestion.t`, *default:* `nil`) - A respondent can choose a rating from a pre-defined set of icons.
2930
* `required` (*type:* `boolean()`, *default:* `nil`) - Whether the question must be answered in order for a respondent to submit their response.
3031
* `rowQuestion` (*type:* `GoogleApi.Forms.V1.Model.RowQuestion.t`, *default:* `nil`) - A row of a QuestionGroupItem.
3132
* `scaleQuestion` (*type:* `GoogleApi.Forms.V1.Model.ScaleQuestion.t`, *default:* `nil`) - A respondent can choose a number from a range.
@@ -41,6 +42,7 @@ defmodule GoogleApi.Forms.V1.Model.Question do
4142
:fileUploadQuestion => GoogleApi.Forms.V1.Model.FileUploadQuestion.t() | nil,
4243
:grading => GoogleApi.Forms.V1.Model.Grading.t() | nil,
4344
:questionId => String.t() | nil,
45+
:ratingQuestion => GoogleApi.Forms.V1.Model.RatingQuestion.t() | nil,
4446
:required => boolean() | nil,
4547
:rowQuestion => GoogleApi.Forms.V1.Model.RowQuestion.t() | nil,
4648
:scaleQuestion => GoogleApi.Forms.V1.Model.ScaleQuestion.t() | nil,
@@ -53,6 +55,7 @@ defmodule GoogleApi.Forms.V1.Model.Question do
5355
field(:fileUploadQuestion, as: GoogleApi.Forms.V1.Model.FileUploadQuestion)
5456
field(:grading, as: GoogleApi.Forms.V1.Model.Grading)
5557
field(:questionId)
58+
field(:ratingQuestion, as: GoogleApi.Forms.V1.Model.RatingQuestion)
5659
field(:required)
5760
field(:rowQuestion, as: GoogleApi.Forms.V1.Model.RowQuestion)
5861
field(:scaleQuestion, as: GoogleApi.Forms.V1.Model.ScaleQuestion)
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.Forms.V1.Model.RatingQuestion do
19+
@moduledoc """
20+
A rating question. The user has a range of icons to choose from.
21+
22+
## Attributes
23+
24+
* `iconType` (*type:* `String.t`, *default:* `nil`) - Required. The icon type to use for the rating.
25+
* `ratingScaleLevel` (*type:* `integer()`, *default:* `nil`) - Required. The rating scale level of the rating question.
26+
"""
27+
28+
use GoogleApi.Gax.ModelBase
29+
30+
@type t :: %__MODULE__{
31+
:iconType => String.t() | nil,
32+
:ratingScaleLevel => integer() | nil
33+
}
34+
35+
field(:iconType)
36+
field(:ratingScaleLevel)
37+
end
38+
39+
defimpl Poison.Decoder, for: GoogleApi.Forms.V1.Model.RatingQuestion do
40+
def decode(value, options) do
41+
GoogleApi.Forms.V1.Model.RatingQuestion.decode(value, options)
42+
end
43+
end
44+
45+
defimpl Poison.Encoder, for: GoogleApi.Forms.V1.Model.RatingQuestion do
46+
def encode(value, options) do
47+
GoogleApi.Gax.ModelBase.encode(value, options)
48+
end
49+
end

clients/forms/mix.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
defmodule GoogleApi.Forms.Mixfile do
1919
use Mix.Project
2020

21-
@version "0.3.0"
21+
@version "0.4.0"
2222

2323
def project() do
2424
[

0 commit comments

Comments
 (0)