-
Notifications
You must be signed in to change notification settings - Fork 461
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Automated regeneration of Translate client (#10864)
Auto-created at 2024-03-12 01:28:26 +0000 using the toys pull request generator.
- Loading branch information
1 parent
480932d
commit 3f65ecb
Showing
47 changed files
with
3,352 additions
and
124 deletions.
There are no files selected for viewing
1,919 changes: 1,824 additions & 95 deletions
1,919
clients/translate/lib/google_api/translate/v3/api/projects.ex
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
64 changes: 64 additions & 0 deletions
64
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_dataset.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtDataset do | ||
@moduledoc """ | ||
An Adaptive MT Dataset. | ||
## Attributes | ||
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this dataset was created. | ||
* `displayName` (*type:* `String.t`, *default:* `nil`) - The name of the dataset to show in the interface. The name can be up to 32 characters long and can consist only of ASCII Latin letters A-Z and a-z, underscores (_), and ASCII digits 0-9. | ||
* `exampleCount` (*type:* `integer()`, *default:* `nil`) - The number of examples in the dataset. | ||
* `name` (*type:* `String.t`, *default:* `nil`) - Required. The resource name of the dataset, in form of `projects/{project-number-or-id}/locations/{location_id}/adaptiveMtDatasets/{dataset_id}` | ||
* `sourceLanguageCode` (*type:* `String.t`, *default:* `nil`) - The BCP-47 language code of the source language. | ||
* `targetLanguageCode` (*type:* `String.t`, *default:* `nil`) - The BCP-47 language code of the target language. | ||
* `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this dataset was last updated. | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:createTime => DateTime.t() | nil, | ||
:displayName => String.t() | nil, | ||
:exampleCount => integer() | nil, | ||
:name => String.t() | nil, | ||
:sourceLanguageCode => String.t() | nil, | ||
:targetLanguageCode => String.t() | nil, | ||
:updateTime => DateTime.t() | nil | ||
} | ||
|
||
field(:createTime, as: DateTime) | ||
field(:displayName) | ||
field(:exampleCount) | ||
field(:name) | ||
field(:sourceLanguageCode) | ||
field(:targetLanguageCode) | ||
field(:updateTime, as: DateTime) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtDataset do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtDataset.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtDataset do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
58 changes: 58 additions & 0 deletions
58
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_file.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtFile do | ||
@moduledoc """ | ||
An AdaptiveMtFile. | ||
## Attributes | ||
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this file was created. | ||
* `displayName` (*type:* `String.t`, *default:* `nil`) - The file's display name. | ||
* `entryCount` (*type:* `integer()`, *default:* `nil`) - The number of entries that the file contains. | ||
* `name` (*type:* `String.t`, *default:* `nil`) - Required. The resource name of the file, in form of `projects/{project-number-or-id}/locations/{location_id}/adaptiveMtDatasets/{dataset}/adaptiveMtFiles/{file}` | ||
* `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this file was last updated. | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:createTime => DateTime.t() | nil, | ||
:displayName => String.t() | nil, | ||
:entryCount => integer() | nil, | ||
:name => String.t() | nil, | ||
:updateTime => DateTime.t() | nil | ||
} | ||
|
||
field(:createTime, as: DateTime) | ||
field(:displayName) | ||
field(:entryCount) | ||
field(:name) | ||
field(:updateTime, as: DateTime) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtFile do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtFile.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtFile do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
58 changes: 58 additions & 0 deletions
58
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_sentence.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtSentence do | ||
@moduledoc """ | ||
An AdaptiveMt sentence entry. | ||
## Attributes | ||
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this sentence was created. | ||
* `name` (*type:* `String.t`, *default:* `nil`) - Required. The resource name of the file, in form of `projects/{project-number-or-id}/locations/{location_id}/adaptiveMtDatasets/{dataset}/adaptiveMtFiles/{file}/adaptiveMtSentences/{sentence}` | ||
* `sourceSentence` (*type:* `String.t`, *default:* `nil`) - Required. The source sentence. | ||
* `targetSentence` (*type:* `String.t`, *default:* `nil`) - Required. The target sentence. | ||
* `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp when this sentence was last updated. | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:createTime => DateTime.t() | nil, | ||
:name => String.t() | nil, | ||
:sourceSentence => String.t() | nil, | ||
:targetSentence => String.t() | nil, | ||
:updateTime => DateTime.t() | nil | ||
} | ||
|
||
field(:createTime, as: DateTime) | ||
field(:name) | ||
field(:sourceSentence) | ||
field(:targetSentence) | ||
field(:updateTime, as: DateTime) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtSentence do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtSentence.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtSentence do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
49 changes: 49 additions & 0 deletions
49
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_translate_request.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtTranslateRequest do | ||
@moduledoc """ | ||
The request for sending an AdaptiveMt translation query. | ||
## Attributes | ||
* `content` (*type:* `list(String.t)`, *default:* `nil`) - Required. The content of the input in string format. For now only one sentence per request is supported. | ||
* `dataset` (*type:* `String.t`, *default:* `nil`) - Required. The resource name for the dataset to use for adaptive MT. `projects/{project}/locations/{location-id}/adaptiveMtDatasets/{dataset}` | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:content => list(String.t()) | nil, | ||
:dataset => String.t() | nil | ||
} | ||
|
||
field(:content, type: :list) | ||
field(:dataset) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslateRequest do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtTranslateRequest.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslateRequest do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
49 changes: 49 additions & 0 deletions
49
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_translate_response.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtTranslateResponse do | ||
@moduledoc """ | ||
An AdaptiveMtTranslate response. | ||
## Attributes | ||
* `languageCode` (*type:* `String.t`, *default:* `nil`) - Output only. The translation's language code. | ||
* `translations` (*type:* `list(GoogleApi.Translate.V3.Model.AdaptiveMtTranslation.t)`, *default:* `nil`) - Output only. The translation. | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:languageCode => String.t() | nil, | ||
:translations => list(GoogleApi.Translate.V3.Model.AdaptiveMtTranslation.t()) | nil | ||
} | ||
|
||
field(:languageCode) | ||
field(:translations, as: GoogleApi.Translate.V3.Model.AdaptiveMtTranslation, type: :list) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslateResponse do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtTranslateResponse.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslateResponse do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
46 changes: 46 additions & 0 deletions
46
clients/translate/lib/google_api/translate/v3/model/adaptive_mt_translation.ex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Copyright 2019 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# NOTE: This file is auto generated by the elixir code generator program. | ||
# Do not edit this file manually. | ||
|
||
defmodule GoogleApi.Translate.V3.Model.AdaptiveMtTranslation do | ||
@moduledoc """ | ||
An AdaptiveMt translation. | ||
## Attributes | ||
* `translatedText` (*type:* `String.t`, *default:* `nil`) - Output only. The translated text. | ||
""" | ||
|
||
use GoogleApi.Gax.ModelBase | ||
|
||
@type t :: %__MODULE__{ | ||
:translatedText => String.t() | nil | ||
} | ||
|
||
field(:translatedText) | ||
end | ||
|
||
defimpl Poison.Decoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslation do | ||
def decode(value, options) do | ||
GoogleApi.Translate.V3.Model.AdaptiveMtTranslation.decode(value, options) | ||
end | ||
end | ||
|
||
defimpl Poison.Encoder, for: GoogleApi.Translate.V3.Model.AdaptiveMtTranslation do | ||
def encode(value, options) do | ||
GoogleApi.Gax.ModelBase.encode(value, options) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.