Skip to content
This repository has been archived by the owner on Dec 15, 2023. It is now read-only.

Commit

Permalink
feat: add total_billed_time response field
Browse files Browse the repository at this point in the history
Committer: @cherba
PiperOrigin-RevId: 387131819

Source-Author: Google APIs <noreply@google.com>
Source-Date: Tue Jul 27 09:49:47 2021 -0700
Source-Repo: googleapis/googleapis
Source-Sha: 4fca877897a4639796bba0731c6f579724d80d72
Source-Link: googleapis/googleapis@4fca877

Co-authored-by: Neenu Shaji <Neenu1995@users.noreply.github.com>

fix: phrase_set_id is required field in CreatePhraseSetRequest
fix: custom_class_id is required field in CreateCustomClassRequest.
  • Loading branch information
yoshi-automation committed Aug 10, 2021
1 parent 8bfebf0 commit 08ff216
Show file tree
Hide file tree
Showing 21 changed files with 1,222 additions and 235 deletions.
Expand Up @@ -170,8 +170,8 @@ public AdaptationStub getStub() {
* @param parent Required. The parent resource where this phrase set will be created. Format:
* {api_version}/projects/{project}/locations/{location}/phraseSets
* @param phraseSet Required. The phrase set to create.
* @param phraseSetId The ID to use for the phrase set, which will become the final component of
* the phrase set's resource name.
* @param phraseSetId Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* <p>This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
Expand Down Expand Up @@ -206,8 +206,8 @@ public final PhraseSet createPhraseSet(
* @param parent Required. The parent resource where this phrase set will be created. Format:
* {api_version}/projects/{project}/locations/{location}/phraseSets
* @param phraseSet Required. The phrase set to create.
* @param phraseSetId The ID to use for the phrase set, which will become the final component of
* the phrase set's resource name.
* @param phraseSetId Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* <p>This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
Expand Down Expand Up @@ -687,8 +687,8 @@ public final UnaryCallable<DeletePhraseSetRequest, Empty> deletePhraseSetCallabl
* @param parent Required. The parent resource where this custom class will be created. Format:
* {api_version}/projects/{project}/locations/{location}/customClasses
* @param customClass Required. The custom class to create.
* @param customClassId The ID to use for the custom class, which will become the final component
* of the custom class' resource name.
* @param customClassId Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* <p>This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
Expand Down Expand Up @@ -721,8 +721,8 @@ public final CustomClass createCustomClass(
* @param parent Required. The parent resource where this custom class will be created. Format:
* {api_version}/projects/{project}/locations/{location}/customClasses
* @param customClass Required. The custom class to create.
* @param customClassId The ID to use for the custom class, which will become the final component
* of the custom class' resource name.
* @param customClassId Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* <p>This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
Expand Down
Expand Up @@ -30,6 +30,7 @@
import com.google.longrunning.Operation;
import com.google.protobuf.AbstractMessage;
import com.google.protobuf.Any;
import com.google.protobuf.Duration;
import com.google.rpc.Status;
import io.grpc.StatusRuntimeException;
import java.io.IOException;
Expand Down Expand Up @@ -89,6 +90,7 @@ public void recognizeTest() throws Exception {
RecognizeResponse expectedResponse =
RecognizeResponse.newBuilder()
.addAllResults(new ArrayList<SpeechRecognitionResult>())
.setTotalBilledTime(Duration.newBuilder().build())
.build();
mockSpeech.addResponse(expectedResponse);

Expand Down Expand Up @@ -130,6 +132,7 @@ public void longRunningRecognizeTest() throws Exception {
LongRunningRecognizeResponse expectedResponse =
LongRunningRecognizeResponse.newBuilder()
.addAllResults(new ArrayList<SpeechRecognitionResult>())
.setTotalBilledTime(Duration.newBuilder().build())
.setOutputConfig(TranscriptOutputConfig.newBuilder().build())
.setOutputError(Status.newBuilder().build())
.build();
Expand Down Expand Up @@ -184,6 +187,7 @@ public void streamingRecognizeTest() throws Exception {
StreamingRecognizeResponse.newBuilder()
.setError(Status.newBuilder().build())
.addAllResults(new ArrayList<StreamingRecognitionResult>())
.setTotalBilledTime(Duration.newBuilder().build())
.build();
mockSpeech.addResponse(expectedResponse);
StreamingRecognizeRequest request = StreamingRecognizeRequest.newBuilder().build();
Expand Down
Expand Up @@ -198,13 +198,13 @@ public com.google.protobuf.ByteString getParentBytes() {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The customClassId.
*/
Expand All @@ -224,13 +224,13 @@ public java.lang.String getCustomClassId() {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for customClassId.
*/
Expand Down Expand Up @@ -795,13 +795,13 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The customClassId.
*/
Expand All @@ -820,13 +820,13 @@ public java.lang.String getCustomClassId() {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for customClassId.
*/
Expand All @@ -845,13 +845,13 @@ public com.google.protobuf.ByteString getCustomClassIdBytes() {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @param value The customClassId to set.
* @return This builder for chaining.
Expand All @@ -869,13 +869,13 @@ public Builder setCustomClassId(java.lang.String value) {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return This builder for chaining.
*/
Expand All @@ -889,13 +889,13 @@ public Builder clearCustomClassId() {
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @param value The bytes for customClassId to set.
* @return This builder for chaining.
Expand Down
Expand Up @@ -60,13 +60,13 @@ public interface CreateCustomClassRequestOrBuilder
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The customClassId.
*/
Expand All @@ -75,13 +75,13 @@ public interface CreateCustomClassRequestOrBuilder
*
*
* <pre>
* The ID to use for the custom class, which will become the final
* Required. The ID to use for the custom class, which will become the final
* component of the custom class' resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string custom_class_id = 2;</code>
* <code>string custom_class_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for customClassId.
*/
Expand Down
Expand Up @@ -198,13 +198,13 @@ public com.google.protobuf.ByteString getParentBytes() {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The phraseSetId.
*/
Expand All @@ -224,13 +224,13 @@ public java.lang.String getPhraseSetId() {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for phraseSetId.
*/
Expand Down Expand Up @@ -795,13 +795,13 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The phraseSetId.
*/
Expand All @@ -820,13 +820,13 @@ public java.lang.String getPhraseSetId() {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for phraseSetId.
*/
Expand All @@ -845,13 +845,13 @@ public com.google.protobuf.ByteString getPhraseSetIdBytes() {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @param value The phraseSetId to set.
* @return This builder for chaining.
Expand All @@ -869,13 +869,13 @@ public Builder setPhraseSetId(java.lang.String value) {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return This builder for chaining.
*/
Expand All @@ -889,13 +889,13 @@ public Builder clearPhraseSetId() {
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @param value The bytes for phraseSetId to set.
* @return This builder for chaining.
Expand Down
Expand Up @@ -60,13 +60,13 @@ public interface CreatePhraseSetRequestOrBuilder
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The phraseSetId.
*/
Expand All @@ -75,13 +75,13 @@ public interface CreatePhraseSetRequestOrBuilder
*
*
* <pre>
* The ID to use for the phrase set, which will become the final
* Required. The ID to use for the phrase set, which will become the final
* component of the phrase set's resource name.
* This value should be 4-63 characters, and valid characters
* are /[a-z][0-9]-/.
* </pre>
*
* <code>string phrase_set_id = 2;</code>
* <code>string phrase_set_id = 2 [(.google.api.field_behavior) = REQUIRED];</code>
*
* @return The bytes for phraseSetId.
*/
Expand Down

0 comments on commit 08ff216

Please sign in to comment.