This class provides the ability to make remote calls to the backing service through method * calls that map to API methods. Sample code to get started: * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }+ * *
Note: close() needs to be called on the LanguageServiceClient object to clean up resources * such as threads. In the example above, try-with-resources is used, which automatically calls * close(). @@ -139,6 +146,15 @@ public LanguageServiceStub getStub() { /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }+ * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -152,6 +168,17 @@ public final AnalyzeSentimentResponse analyzeSentiment(Document document) { /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeSentimentResponse response = + * languageServiceClient.analyzeSentiment(document, encodingType); + * } + * }+ * * @param document Input document. * @param encodingType The encoding type used by the API to calculate sentence offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -170,6 +197,16 @@ public final AnalyzeSentimentResponse analyzeSentiment( /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSentimentRequest request = + * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -182,6 +219,17 @@ public final AnalyzeSentimentResponse analyzeSentiment(AnalyzeSentimentRequest r * Analyzes the sentiment of the provided text. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSentimentRequest request = + * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeSentimentCallable().futureCall(request); + * // Do something. + * AnalyzeSentimentResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(document); + * } + * }+ * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -207,6 +264,17 @@ public final AnalyzeEntitiesResponse analyzeEntities(Document document) { * Finds named entities (currently proper names and common nouns) in the text along with entity * types, salience, mentions for each entity, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeEntitiesResponse response = + * languageServiceClient.analyzeEntities(document, encodingType); + * } + * }+ * * @param document Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -226,6 +294,16 @@ public final AnalyzeEntitiesResponse analyzeEntities( * Finds named entities (currently proper names and common nouns) in the text along with entity * types, salience, mentions for each entity, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitiesRequest request = + * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -239,6 +317,17 @@ public final AnalyzeEntitiesResponse analyzeEntities(AnalyzeEntitiesRequest requ * types, salience, mentions for each entity, and other properties. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitiesRequest request = + * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeEntitiesCallable().futureCall(request); + * // Do something. + * AnalyzeEntitiesResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(document); + * } + * }+ * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -266,6 +365,17 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment(Document docu * [AnalyzeEntities][google.cloud.language.v1.LanguageService.AnalyzeEntities] in the text and * analyzes sentiment associated with each entity and its mentions. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(document, encodingType); + * } + * }+ * * @param document Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -286,6 +396,19 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * [AnalyzeEntities][google.cloud.language.v1.LanguageService.AnalyzeEntities] in the text and * analyzes sentiment associated with each entity and its mentions. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitySentimentRequest request = + * AnalyzeEntitySentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .build(); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -301,6 +424,19 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * analyzes sentiment associated with each entity and its mentions. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitySentimentRequest request = + * AnalyzeEntitySentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeEntitySentimentCallable().futureCall(request); + * // Do something. + * AnalyzeEntitySentimentResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(document); + * } + * }+ * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -325,6 +470,16 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document) { * Analyzes the syntax of the text and provides sentence boundaries and tokenization along with * part of speech tags, dependency trees, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(document, encodingType); + * } + * }+ * * @param document Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -343,6 +498,16 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document, EncodingType * Analyzes the syntax of the text and provides sentence boundaries and tokenization along with * part of speech tags, dependency trees, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSyntaxRequest request = + * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -356,6 +521,17 @@ public final AnalyzeSyntaxResponse analyzeSyntax(AnalyzeSyntaxRequest request) { * part of speech tags, dependency trees, and other properties. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSyntaxRequest request = + * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeSyntaxCallable().futureCall(request); + * // Do something. + * AnalyzeSyntaxResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * ClassifyTextResponse response = languageServiceClient.classifyText(document); + * } + * }+ * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -377,6 +562,16 @@ public final ClassifyTextResponse classifyText(Document document) { /** * Classifies a document into categories. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * ClassifyTextRequest request = + * ClassifyTextRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ClassifyTextResponse response = languageServiceClient.classifyText(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -389,6 +584,17 @@ public final ClassifyTextResponse classifyText(ClassifyTextRequest request) { * Classifies a document into categories. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * ClassifyTextRequest request = + * ClassifyTextRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.classifyTextCallable().futureCall(request); + * // Do something. + * ClassifyTextResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnnotateTextRequest.Features features = AnnotateTextRequest.Features.newBuilder().build(); + * AnnotateTextResponse response = languageServiceClient.annotateText(document, features); + * } + * }+ * * @param document Input document. * @param features The enabled features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -415,6 +631,18 @@ public final AnnotateTextResponse annotateText( * A convenience method that provides all the features that analyzeSentiment, analyzeEntities, and * analyzeSyntax provide in one call. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnnotateTextRequest.Features features = AnnotateTextRequest.Features.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnnotateTextResponse response = + * languageServiceClient.annotateText(document, features, encodingType); + * } + * }+ * * @param document Input document. * @param features The enabled features. * @param encodingType The encoding type used by the API to calculate offsets. @@ -436,6 +664,19 @@ public final AnnotateTextResponse annotateText( * A convenience method that provides all the features that analyzeSentiment, analyzeEntities, and * analyzeSyntax provide in one call. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnnotateTextRequest request = + * AnnotateTextRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .build(); + * AnnotateTextResponse response = languageServiceClient.annotateText(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -449,6 +690,20 @@ public final AnnotateTextResponse annotateText(AnnotateTextRequest request) { * analyzeSyntax provide in one call. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnnotateTextRequest request = + * AnnotateTextRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.annotateTextCallable().futureCall(request); + * // Do something. + * AnnotateTextResponse response = future.get(); + * } + * }
Sample for LanguageServiceClient: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }*/ @Generated("by gapic-generator-java") package com.google.cloud.language.v1; diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java index 53108798..396b0598 100644 --- a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java @@ -33,6 +33,13 @@ *
This class provides the ability to make remote calls to the backing service through method * calls that map to API methods. Sample code to get started: * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }+ * *
Note: close() needs to be called on the LanguageServiceClient object to clean up resources * such as threads. In the example above, try-with-resources is used, which automatically calls * close(). @@ -140,6 +147,15 @@ public LanguageServiceStub getStub() { /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }+ * * @param document Required. Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -153,6 +169,17 @@ public final AnalyzeSentimentResponse analyzeSentiment(Document document) { /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeSentimentResponse response = + * languageServiceClient.analyzeSentiment(document, encodingType); + * } + * }+ * * @param document Required. Input document. * @param encodingType The encoding type used by the API to calculate sentence offsets for the * sentence sentiment. @@ -172,6 +199,16 @@ public final AnalyzeSentimentResponse analyzeSentiment( /** * Analyzes the sentiment of the provided text. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSentimentRequest request = + * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -184,6 +221,17 @@ public final AnalyzeSentimentResponse analyzeSentiment(AnalyzeSentimentRequest r * Analyzes the sentiment of the provided text. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSentimentRequest request = + * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeSentimentCallable().futureCall(request); + * // Do something. + * AnalyzeSentimentResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(document); + * } + * }+ * * @param document Required. Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -209,6 +266,17 @@ public final AnalyzeEntitiesResponse analyzeEntities(Document document) { * Finds named entities (currently proper names and common nouns) in the text along with entity * types, salience, mentions for each entity, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeEntitiesResponse response = + * languageServiceClient.analyzeEntities(document, encodingType); + * } + * }+ * * @param document Required. Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -228,6 +296,16 @@ public final AnalyzeEntitiesResponse analyzeEntities( * Finds named entities (currently proper names and common nouns) in the text along with entity * types, salience, mentions for each entity, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitiesRequest request = + * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -241,6 +319,17 @@ public final AnalyzeEntitiesResponse analyzeEntities(AnalyzeEntitiesRequest requ * types, salience, mentions for each entity, and other properties. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitiesRequest request = + * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeEntitiesCallable().futureCall(request); + * // Do something. + * AnalyzeEntitiesResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(document); + * } + * }+ * * @param document Required. Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -268,6 +367,17 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment(Document docu * [AnalyzeEntities][google.cloud.language.v1beta2.LanguageService.AnalyzeEntities] in the text * and analyzes sentiment associated with each entity and its mentions. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(document, encodingType); + * } + * }+ * * @param document Required. Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -288,6 +398,19 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * [AnalyzeEntities][google.cloud.language.v1beta2.LanguageService.AnalyzeEntities] in the text * and analyzes sentiment associated with each entity and its mentions. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitySentimentRequest request = + * AnalyzeEntitySentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .build(); + * AnalyzeEntitySentimentResponse response = + * languageServiceClient.analyzeEntitySentiment(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -303,6 +426,19 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * and analyzes sentiment associated with each entity and its mentions. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeEntitySentimentRequest request = + * AnalyzeEntitySentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeEntitySentimentCallable().futureCall(request); + * // Do something. + * AnalyzeEntitySentimentResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(document); + * } + * }+ * * @param document Required. Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -327,6 +472,16 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document) { * Analyzes the syntax of the text and provides sentence boundaries and tokenization along with * part-of-speech tags, dependency trees, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(document, encodingType); + * } + * }+ * * @param document Required. Input document. * @param encodingType The encoding type used by the API to calculate offsets. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -345,6 +500,16 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document, EncodingType * Analyzes the syntax of the text and provides sentence boundaries and tokenization along with * part-of-speech tags, dependency trees, and other properties. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSyntaxRequest request = + * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -358,6 +523,17 @@ public final AnalyzeSyntaxResponse analyzeSyntax(AnalyzeSyntaxRequest request) { * part-of-speech tags, dependency trees, and other properties. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnalyzeSyntaxRequest request = + * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.analyzeSyntaxCallable().futureCall(request); + * // Do something. + * AnalyzeSyntaxResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * ClassifyTextResponse response = languageServiceClient.classifyText(document); + * } + * }+ * * @param document Required. Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -379,6 +564,16 @@ public final ClassifyTextResponse classifyText(Document document) { /** * Classifies a document into categories. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * ClassifyTextRequest request = + * ClassifyTextRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ClassifyTextResponse response = languageServiceClient.classifyText(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -391,6 +586,17 @@ public final ClassifyTextResponse classifyText(ClassifyTextRequest request) { * Classifies a document into categories. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * ClassifyTextRequest request = + * ClassifyTextRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.classifyTextCallable().futureCall(request); + * // Do something. + * ClassifyTextResponse response = future.get(); + * } + * }
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnnotateTextRequest.Features features = AnnotateTextRequest.Features.newBuilder().build(); + * AnnotateTextResponse response = languageServiceClient.annotateText(document, features); + * } + * }+ * * @param document Required. Input document. * @param features Required. The enabled features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -417,6 +633,18 @@ public final AnnotateTextResponse annotateText( * A convenience method that provides all syntax, sentiment, entity, and classification features * in one call. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnnotateTextRequest.Features features = AnnotateTextRequest.Features.newBuilder().build(); + * EncodingType encodingType = EncodingType.forNumber(0); + * AnnotateTextResponse response = + * languageServiceClient.annotateText(document, features, encodingType); + * } + * }+ * * @param document Required. Input document. * @param features Required. The enabled features. * @param encodingType The encoding type used by the API to calculate offsets. @@ -438,6 +666,19 @@ public final AnnotateTextResponse annotateText( * A convenience method that provides all syntax, sentiment, entity, and classification features * in one call. * + *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnnotateTextRequest request = + * AnnotateTextRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .build(); + * AnnotateTextResponse response = languageServiceClient.annotateText(request); + * } + * }+ * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -451,6 +692,20 @@ public final AnnotateTextResponse annotateText(AnnotateTextRequest request) { * in one call. * *
Sample code: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * AnnotateTextRequest request = + * AnnotateTextRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .build(); + * ApiFuture*/ public final UnaryCallablefuture = + * languageServiceClient.annotateTextCallable().futureCall(request); + * // Do something. + * AnnotateTextResponse response = future.get(); + * } + * }
Sample for LanguageServiceClient: + * + *
{@code + * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { + * Document document = Document.newBuilder().build(); + * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); + * } + * }*/ @Generated("by gapic-generator-java") package com.google.cloud.language.v1beta2; diff --git a/synth.metadata b/synth.metadata index 71ef9859..1d36e9a2 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,23 +4,23 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-language.git", - "sha": "f7aab9f86fa484d7606394bc8782b8bca391492f" + "sha": "3a2521ed980fb50e5707e9c6927d720bd71245c6" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "91e206bcfeaf8948ea03fe3cb1b7616108496cd3", - "internalRef": "350949863" + "sha": "8d8c008e56f1af31d57f75561e0f1848ffb29eeb", + "internalRef": "356341083" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "91e206bcfeaf8948ea03fe3cb1b7616108496cd3", - "internalRef": "350949863" + "sha": "8d8c008e56f1af31d57f75561e0f1848ffb29eeb", + "internalRef": "356341083" } }, { From 5ea06e65868be7219a18328d254c49c7f7980131 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot
{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSentimentRequest request = - * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(request); * } * }@@ -223,7 +226,10 @@ public final AnalyzeSentimentResponse analyzeSentiment(AnalyzeSentimentRequest r *
{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSentimentRequest request = - * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeSentimentCallable().futureCall(request); * // Do something. @@ -299,7 +305,10 @@ public final AnalyzeEntitiesResponse analyzeEntities( * {@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeEntitiesRequest request = - * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(request); * } * }@@ -321,7 +330,10 @@ public final AnalyzeEntitiesResponse analyzeEntities(AnalyzeEntitiesRequest requ *{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeEntitiesRequest request = - * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeEntitiesCallable().futureCall(request); * // Do something. @@ -403,6 +415,7 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * AnalyzeEntitySentimentRequest request = * AnalyzeEntitySentimentRequest.newBuilder() * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * AnalyzeEntitySentimentResponse response = * languageServiceClient.analyzeEntitySentiment(request); @@ -430,6 +443,7 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * AnalyzeEntitySentimentRequest request = * AnalyzeEntitySentimentRequest.newBuilder() * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * ApiFuture future = * languageServiceClient.analyzeEntitySentimentCallable().futureCall(request); @@ -503,7 +517,10 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document, EncodingType * {@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSyntaxRequest request = - * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(request); * } * }@@ -525,7 +542,10 @@ public final AnalyzeSyntaxResponse analyzeSyntax(AnalyzeSyntaxRequest request) { *{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSyntaxRequest request = - * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeSyntaxCallable().futureCall(request); * // Do something. @@ -672,6 +692,7 @@ public final AnnotateTextResponse annotateText( * AnnotateTextRequest.newBuilder() * .setDocument(Document.newBuilder().build()) * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * AnnotateTextResponse response = languageServiceClient.annotateText(request); * } @@ -697,6 +718,7 @@ public final AnnotateTextResponse annotateText(AnnotateTextRequest request) { * AnnotateTextRequest.newBuilder() * .setDocument(Document.newBuilder().build()) * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * ApiFuture future = * languageServiceClient.annotateTextCallable().futureCall(request); diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceStub.java b/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceStub.java index 8aef5392..0aab6121 100644 --- a/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceStub.java +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceStub.java @@ -227,28 +227,34 @@ public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @Override public UnaryCallable analyzeSentimentCallable() { return analyzeSentimentCallable; } + @Override public UnaryCallable analyzeEntitiesCallable() { return analyzeEntitiesCallable; } + @Override public UnaryCallable analyzeEntitySentimentCallable() { return analyzeEntitySentimentCallable; } + @Override public UnaryCallable analyzeSyntaxCallable() { return analyzeSyntaxCallable; } + @Override public UnaryCallable classifyTextCallable() { return classifyTextCallable; } + @Override public UnaryCallable annotateTextCallable() { return annotateTextCallable; } diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java index 396b0598..a57a9796 100644 --- a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java @@ -204,7 +204,10 @@ public final AnalyzeSentimentResponse analyzeSentiment( * {@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSentimentRequest request = - * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(request); * } * }@@ -225,7 +228,10 @@ public final AnalyzeSentimentResponse analyzeSentiment(AnalyzeSentimentRequest r *{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSentimentRequest request = - * AnalyzeSentimentRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSentimentRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeSentimentCallable().futureCall(request); * // Do something. @@ -301,7 +307,10 @@ public final AnalyzeEntitiesResponse analyzeEntities( * {@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeEntitiesRequest request = - * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeEntitiesResponse response = languageServiceClient.analyzeEntities(request); * } * }@@ -323,7 +332,10 @@ public final AnalyzeEntitiesResponse analyzeEntities(AnalyzeEntitiesRequest requ *{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeEntitiesRequest request = - * AnalyzeEntitiesRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeEntitiesRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeEntitiesCallable().futureCall(request); * // Do something. @@ -405,6 +417,7 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * AnalyzeEntitySentimentRequest request = * AnalyzeEntitySentimentRequest.newBuilder() * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * AnalyzeEntitySentimentResponse response = * languageServiceClient.analyzeEntitySentiment(request); @@ -432,6 +445,7 @@ public final AnalyzeEntitySentimentResponse analyzeEntitySentiment( * AnalyzeEntitySentimentRequest request = * AnalyzeEntitySentimentRequest.newBuilder() * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * ApiFuture future = * languageServiceClient.analyzeEntitySentimentCallable().futureCall(request); @@ -505,7 +519,10 @@ public final AnalyzeSyntaxResponse analyzeSyntax(Document document, EncodingType * {@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSyntaxRequest request = - * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * AnalyzeSyntaxResponse response = languageServiceClient.analyzeSyntax(request); * } * }@@ -527,7 +544,10 @@ public final AnalyzeSyntaxResponse analyzeSyntax(AnalyzeSyntaxRequest request) { *{@code * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * AnalyzeSyntaxRequest request = - * AnalyzeSyntaxRequest.newBuilder().setDocument(Document.newBuilder().build()).build(); + * AnalyzeSyntaxRequest.newBuilder() + * .setDocument(Document.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) + * .build(); * ApiFuturefuture = * languageServiceClient.analyzeSyntaxCallable().futureCall(request); * // Do something. @@ -674,6 +694,7 @@ public final AnnotateTextResponse annotateText( * AnnotateTextRequest.newBuilder() * .setDocument(Document.newBuilder().build()) * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * AnnotateTextResponse response = languageServiceClient.annotateText(request); * } @@ -699,6 +720,7 @@ public final AnnotateTextResponse annotateText(AnnotateTextRequest request) { * AnnotateTextRequest.newBuilder() * .setDocument(Document.newBuilder().build()) * .setFeatures(AnnotateTextRequest.Features.newBuilder().build()) + * .setEncodingType(EncodingType.forNumber(0)) * .build(); * ApiFuture future = * languageServiceClient.annotateTextCallable().futureCall(request); diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceStub.java b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceStub.java index a6fd42b1..4a3ea288 100644 --- a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceStub.java +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceStub.java @@ -230,28 +230,34 @@ public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @Override public UnaryCallable analyzeSentimentCallable() { return analyzeSentimentCallable; } + @Override public UnaryCallable analyzeEntitiesCallable() { return analyzeEntitiesCallable; } + @Override public UnaryCallable analyzeEntitySentimentCallable() { return analyzeEntitySentimentCallable; } + @Override public UnaryCallable analyzeSyntaxCallable() { return analyzeSyntaxCallable; } + @Override public UnaryCallable classifyTextCallable() { return classifyTextCallable; } + @Override public UnaryCallable annotateTextCallable() { return annotateTextCallable; } diff --git a/google-cloud-language/src/test/java/com/google/cloud/language/v1/MockLanguageServiceImpl.java b/google-cloud-language/src/test/java/com/google/cloud/language/v1/MockLanguageServiceImpl.java index 4955e854..28fe01bd 100644 --- a/google-cloud-language/src/test/java/com/google/cloud/language/v1/MockLanguageServiceImpl.java +++ b/google-cloud-language/src/test/java/com/google/cloud/language/v1/MockLanguageServiceImpl.java @@ -69,7 +69,13 @@ public void analyzeSentiment( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeSentiment, expected %s or %s", + response.getClass().getName(), + AnalyzeSentimentResponse.class.getName(), + Exception.class.getName()))); } } @@ -84,7 +90,13 @@ public void analyzeEntities( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeEntities, expected %s or %s", + response.getClass().getName(), + AnalyzeEntitiesResponse.class.getName(), + Exception.class.getName()))); } } @@ -100,7 +112,13 @@ public void analyzeEntitySentiment( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeEntitySentiment, expected %s or %s", + response.getClass().getName(), + AnalyzeEntitySentimentResponse.class.getName(), + Exception.class.getName()))); } } @@ -115,7 +133,13 @@ public void analyzeSyntax( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeSyntax, expected %s or %s", + response.getClass().getName(), + AnalyzeSyntaxResponse.class.getName(), + Exception.class.getName()))); } } @@ -130,7 +154,13 @@ public void classifyText( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ClassifyText, expected %s or %s", + response.getClass().getName(), + ClassifyTextResponse.class.getName(), + Exception.class.getName()))); } } @@ -145,7 +175,13 @@ public void annotateText( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnnotateText, expected %s or %s", + response.getClass().getName(), + AnnotateTextResponse.class.getName(), + Exception.class.getName()))); } } } diff --git a/google-cloud-language/src/test/java/com/google/cloud/language/v1beta2/MockLanguageServiceImpl.java b/google-cloud-language/src/test/java/com/google/cloud/language/v1beta2/MockLanguageServiceImpl.java index aaa97551..635ea020 100644 --- a/google-cloud-language/src/test/java/com/google/cloud/language/v1beta2/MockLanguageServiceImpl.java +++ b/google-cloud-language/src/test/java/com/google/cloud/language/v1beta2/MockLanguageServiceImpl.java @@ -69,7 +69,13 @@ public void analyzeSentiment( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeSentiment, expected %s or %s", + response.getClass().getName(), + AnalyzeSentimentResponse.class.getName(), + Exception.class.getName()))); } } @@ -84,7 +90,13 @@ public void analyzeEntities( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeEntities, expected %s or %s", + response.getClass().getName(), + AnalyzeEntitiesResponse.class.getName(), + Exception.class.getName()))); } } @@ -100,7 +112,13 @@ public void analyzeEntitySentiment( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeEntitySentiment, expected %s or %s", + response.getClass().getName(), + AnalyzeEntitySentimentResponse.class.getName(), + Exception.class.getName()))); } } @@ -115,7 +133,13 @@ public void analyzeSyntax( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnalyzeSyntax, expected %s or %s", + response.getClass().getName(), + AnalyzeSyntaxResponse.class.getName(), + Exception.class.getName()))); } } @@ -130,7 +154,13 @@ public void classifyText( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ClassifyText, expected %s or %s", + response.getClass().getName(), + ClassifyTextResponse.class.getName(), + Exception.class.getName()))); } } @@ -145,7 +175,13 @@ public void annotateText( } else if (response instanceof Exception) { responseObserver.onError(((Exception) response)); } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AnnotateText, expected %s or %s", + response.getClass().getName(), + AnnotateTextResponse.class.getName(), + Exception.class.getName()))); } } } diff --git a/synth.metadata b/synth.metadata index 8af1e0e6..c99b3bfb 100644 --- a/synth.metadata +++ b/synth.metadata @@ -11,16 +11,16 @@ "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "8d8c008e56f1af31d57f75561e0f1848ffb29eeb", - "internalRef": "356341083" + "sha": "e8bc4471a88ac5f60defe3ed436f517174e59ba0", + "internalRef": "357800868" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "8d8c008e56f1af31d57f75561e0f1848ffb29eeb", - "internalRef": "356341083" + "sha": "e8bc4471a88ac5f60defe3ed436f517174e59ba0", + "internalRef": "357800868" } }, { From fa7edcd703fda2ca2d8d06d1a343922c8566331c Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Wed, 17 Feb 2021 09:06:39 -0800 Subject: [PATCH 20/25] chore: update cloud-rad buckets (#377) This PR was generated using Autosynth. :rainbow: Synth log will be available here: https://source.cloud.google.com/results/invocations/80357271-0c99-4119-adf5-bfaf59655fcd/targets - [ ] To automatically regenerate this PR, check this box. Source-Link: https://github.com/googleapis/synthtool/commit/b416a7befcdbc42de41cf387dcf428f894fb812b --- .kokoro/release/publish_javadoc.cfg | 4 ++-- .kokoro/release/publish_javadoc.sh | 2 +- .kokoro/release/publish_javadoc11.cfg | 2 +- .kokoro/release/publish_javadoc11.sh | 2 +- synth.metadata | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.kokoro/release/publish_javadoc.cfg b/.kokoro/release/publish_javadoc.cfg index acd70297..220d2e98 100644 --- a/.kokoro/release/publish_javadoc.cfg +++ b/.kokoro/release/publish_javadoc.cfg @@ -7,10 +7,10 @@ env_vars: { value: "docs-staging" } +# cloud-rad staging env_vars: { key: "STAGING_BUCKET_V2" - value: "docs-staging-v2" - # Production will be at: docs-staging-v2 + value: "docs-staging-v2-staging" } env_vars: { diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh index 588cc90e..7155f7e8 100755 --- a/.kokoro/release/publish_javadoc.sh +++ b/.kokoro/release/publish_javadoc.sh @@ -71,7 +71,7 @@ python3 -m docuploader create-metadata \ --version ${VERSION} \ --language java -# upload docs +# upload docs to staging bucket python3 -m docuploader upload . \ --credentials ${CREDENTIALS} \ --staging-bucket ${STAGING_BUCKET_V2} diff --git a/.kokoro/release/publish_javadoc11.cfg b/.kokoro/release/publish_javadoc11.cfg index aa0380b4..0ffdaa0b 100644 --- a/.kokoro/release/publish_javadoc11.cfg +++ b/.kokoro/release/publish_javadoc11.cfg @@ -1,9 +1,9 @@ # Format: //devtools/kokoro/config/proto/build.proto +# cloud-rad production env_vars: { key: "STAGING_BUCKET_V2" value: "docs-staging-v2" - # Production will be at: docs-staging-v2 } # Configure the docker image for kokoro-trampoline diff --git a/.kokoro/release/publish_javadoc11.sh b/.kokoro/release/publish_javadoc11.sh index a68fe678..6ce78f30 100755 --- a/.kokoro/release/publish_javadoc11.sh +++ b/.kokoro/release/publish_javadoc11.sh @@ -48,7 +48,7 @@ python3 -m docuploader create-metadata \ --version ${VERSION} \ --language java -# upload yml +# upload yml to production bucket python3 -m docuploader upload . \ --credentials ${CREDENTIALS} \ --staging-bucket ${STAGING_BUCKET_V2} \ diff --git a/synth.metadata b/synth.metadata index c99b3bfb..55e65bbb 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-language.git", - "sha": "11544f4d66196936869b0856517324ed18dcd85e" + "sha": "07f8924be8b6d98f9902794f5e3f483c0ac8eb62" } }, { @@ -27,7 +27,7 @@ "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "f327d3b657a63ae4a8efd7f011a15eacae36b59c" + "sha": "b416a7befcdbc42de41cf387dcf428f894fb812b" } } ], From 73e960956bd1f4a968eff1b3143b47f53b1d57dd Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Thu, 18 Feb 2021 16:40:17 -0800 Subject: [PATCH 21/25] build: skip Maven download logs (#378) This PR was generated using Autosynth. :rainbow: Synth log will be available here: https://source.cloud.google.com/results/invocations/1178e66e-5b60-4888-a3e0-033117bbf82f/targets - [ ] To automatically regenerate this PR, check this box. Source-Link: https://github.com/googleapis/synthtool/commit/1aeca92e4a38f47134cb955f52ea76f84f09ff88 --- .kokoro/build.sh | 2 ++ synth.metadata | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.kokoro/build.sh b/.kokoro/build.sh index 65fc63fd..346267e9 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -60,6 +60,7 @@ javadoc) ;; integration) mvn -B ${INTEGRATION_TEST_ARGS} \ + -ntp \ -Penable-integration-tests \ -DtrimStackTrace=false \ -Dclirr.skip=true \ @@ -81,6 +82,7 @@ samples) pushd ${SAMPLES_DIR} mvn -B \ -Penable-samples \ + -ntp \ -DtrimStackTrace=false \ -Dclirr.skip=true \ -Denforcer.skip=true \ diff --git a/synth.metadata b/synth.metadata index 55e65bbb..57d65b29 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-language.git", - "sha": "07f8924be8b6d98f9902794f5e3f483c0ac8eb62" + "sha": "fa7edcd703fda2ca2d8d06d1a343922c8566331c" } }, { @@ -27,7 +27,7 @@ "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "b416a7befcdbc42de41cf387dcf428f894fb812b" + "sha": "1aeca92e4a38f47134cb955f52ea76f84f09ff88" } } ], From 8e181d4ba98c8588b98c5d8b51e33e5c18ca4659 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Fri, 19 Feb 2021 07:48:22 -0800 Subject: [PATCH 22/25] build: reduce download junk in log files (#379) This PR was generated using Autosynth. :rainbow: Synth log will be available here: https://source.cloud.google.com/results/invocations/35eebccc-9702-471c-a3cc-40f197d7330b/targets - [ ] To automatically regenerate this PR, check this box. Source-Link: https://github.com/googleapis/synthtool/commit/6946fd71ae9215b0e7ae188f5057df765ee6d7d2 --- .kokoro/build.sh | 2 +- .kokoro/dependencies.sh | 4 ++-- synth.metadata | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.kokoro/build.sh b/.kokoro/build.sh index 346267e9..14bd0122 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -29,7 +29,7 @@ echo ${JOB_TYPE} # attempt to install 3 times with exponential backoff (starting with 10 seconds) retry_with_backoff 3 10 \ - mvn install -B -V \ + mvn install -B -V -ntp \ -DskipTests=true \ -Dclirr.skip=true \ -Denforcer.skip=true \ diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index c91e5a56..0fb8c843 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -31,7 +31,7 @@ export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=128m" # this should run maven enforcer retry_with_backoff 3 10 \ - mvn install -B -V \ + mvn install -B -V -ntp \ -DskipTests=true \ -Dclirr.skip=true @@ -86,4 +86,4 @@ then else msg "Errors found. See log statements above." exit 1 -fi \ No newline at end of file +fi diff --git a/synth.metadata b/synth.metadata index 57d65b29..e49fbe69 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-language.git", - "sha": "fa7edcd703fda2ca2d8d06d1a343922c8566331c" + "sha": "73e960956bd1f4a968eff1b3143b47f53b1d57dd" } }, { @@ -27,7 +27,7 @@ "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "1aeca92e4a38f47134cb955f52ea76f84f09ff88" + "sha": "6946fd71ae9215b0e7ae188f5057df765ee6d7d2" } } ], From 55d4321a5a10959eb3caf0f4fa9800ffb9fca2c9 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 19 Feb 2021 22:50:20 +0100 Subject: [PATCH 23/25] deps: update dependency com.google.cloud:google-cloud-shared-dependencies to v0.19.0 (#380) [](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | `0.18.0` -> `0.19.0` | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes --- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-language). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 5c5783a4..2c41d889 100644 --- a/pom.xml +++ b/pom.xml @@ -96,7 +96,7 @@googleapis/java-shared-dependencies
### [`v0.19.0`](https://togithub.com/googleapis/java-shared-dependencies/blob/master/CHANGELOG.md#0190-httpswwwgithubcomgoogleapisjava-shared-dependenciescompare0180v0190-2021-02-19) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v0.18.0...v0.19.0) ##### Bug Fixes - update repo name ([#274](https://www.github.com/googleapis/java-shared-dependencies/issues/274)) ([4a98470](https://www.github.com/googleapis/java-shared-dependencies/commit/4a98470b7493c98137191b7bb3cabca23f98628f)) ##### Dependencies - downgrade opencensus version back to 0.28.0 ([#265](https://www.github.com/googleapis/java-shared-dependencies/issues/265)) ([f37025c](https://www.github.com/googleapis/java-shared-dependencies/commit/f37025c70f951b1e34904ee983815c0ed8ec4086)) - update dependency com.google.api-client:google-api-client-bom to v1.31.2 ([#254](https://www.github.com/googleapis/java-shared-dependencies/issues/254)) ([1b0b4a6](https://www.github.com/googleapis/java-shared-dependencies/commit/1b0b4a637cae0c22cd0336c527002025780317d5)) - update dependency com.google.auth:google-auth-library-bom to v0.23.0 ([#261](https://www.github.com/googleapis/java-shared-dependencies/issues/261)) ([1c0b7bd](https://www.github.com/googleapis/java-shared-dependencies/commit/1c0b7bd60b3d73c16cc6c19ab90d8ccedece3706)) - update dependency com.google.cloud:google-cloud-core to v1.94.1 ([#272](https://www.github.com/googleapis/java-shared-dependencies/issues/272)) ([44fd4c3](https://www.github.com/googleapis/java-shared-dependencies/commit/44fd4c3c6cae98bd514525f03462b830050828a8)) - update dependency com.google.errorprone:error_prone_annotations to v2.5.1 ([#255](https://www.github.com/googleapis/java-shared-dependencies/issues/255)) ([6367023](https://www.github.com/googleapis/java-shared-dependencies/commit/63670233424e8f24c3924bba5e2cb6ca97525795)) - update dependency com.google.http-client:google-http-client-bom to v1.38.1 ([#253](https://www.github.com/googleapis/java-shared-dependencies/issues/253)) ([ad87c74](https://www.github.com/googleapis/java-shared-dependencies/commit/ad87c74d9d893726042156d65850806d92e79952)) - update dependency com.google.protobuf:protobuf-bom to v3.15.0 ([#278](https://www.github.com/googleapis/java-shared-dependencies/issues/278)) ([989efbd](https://www.github.com/googleapis/java-shared-dependencies/commit/989efbd29bcf4135f7abce49a697303df2cf1a60)) - update dependency io.grpc:grpc-bom to v1.35.0 ([#248](https://www.github.com/googleapis/java-shared-dependencies/issues/248)) ([7a28c6e](https://www.github.com/googleapis/java-shared-dependencies/commit/7a28c6e7053c181993b1288adcae56de89312113)) - update gax.version to v1.61.0 ([#277](https://www.github.com/googleapis/java-shared-dependencies/issues/277)) ([f1c3fb9](https://www.github.com/googleapis/java-shared-dependencies/commit/f1c3fb9295f2e1c130b9fc329faa60f4f8474ba6)) - update iam.version to v1.0.7 ([#252](https://www.github.com/googleapis/java-shared-dependencies/issues/252)) ([5cb3ed9](https://www.github.com/googleapis/java-shared-dependencies/commit/5cb3ed906537269cd7f8d9ccf4b065754b5f5b48)) - update iam.version to v1.0.8 ([#273](https://www.github.com/googleapis/java-shared-dependencies/issues/273)) ([4d5e7f7](https://www.github.com/googleapis/java-shared-dependencies/commit/4d5e7f720d847918b307a83c95cea10c244ba595))From 21271485b5e91df003c84ef87d5325e2d11bddca Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot com.google.cloud google-cloud-shared-dependencies -0.18.0 +0.19.0 pom import Date: Mon, 22 Feb 2021 09:02:29 -0800 Subject: [PATCH 24/25] chore: release gapic-generator-java v0.0.21 with gapic_metadata.json support (#381) This PR was generated using Autosynth. :rainbow: Synth log will be available here: https://source.cloud.google.com/results/invocations/7984e0da-128a-4b5a-bc15-080e0b735c30/targets - [ ] To automatically regenerate this PR, check this box. PiperOrigin-RevId: 358516065 Source-Link: https://github.com/googleapis/googleapis/commit/af8f71dae961ee036a0ac52a1965270149a6b2c9 --- .../cloud/language/v1/gapic_metadata.json | 36 +++++++++++++++++++ .../language/v1beta2/gapic_metadata.json | 36 +++++++++++++++++++ synth.metadata | 12 ++++--- 3 files changed, 79 insertions(+), 5 deletions(-) create mode 100644 google-cloud-language/src/main/java/com/google/cloud/language/v1/gapic_metadata.json create mode 100644 google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/gapic_metadata.json diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1/gapic_metadata.json b/google-cloud-language/src/main/java/com/google/cloud/language/v1/gapic_metadata.json new file mode 100644 index 00000000..46503565 --- /dev/null +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1/gapic_metadata.json @@ -0,0 +1,36 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "java", + "protoPackage": "google.cloud.language.v1", + "libraryPackage": "com.google.cloud.language.v1", + "services": { + "LanguageService": { + "clients": { + "grpc": { + "libraryClient": "LanguageServiceClient", + "rpcs": { + "AnalyzeEntities": { + "methods": ["analyzeEntities", "analyzeEntities", "analyzeEntities", "analyzeEntitiesCallable"] + }, + "AnalyzeEntitySentiment": { + "methods": ["analyzeEntitySentiment", "analyzeEntitySentiment", "analyzeEntitySentiment", "analyzeEntitySentimentCallable"] + }, + "AnalyzeSentiment": { + "methods": ["analyzeSentiment", "analyzeSentiment", "analyzeSentiment", "analyzeSentimentCallable"] + }, + "AnalyzeSyntax": { + "methods": ["analyzeSyntax", "analyzeSyntax", "analyzeSyntax", "analyzeSyntaxCallable"] + }, + "AnnotateText": { + "methods": ["annotateText", "annotateText", "annotateText", "annotateTextCallable"] + }, + "ClassifyText": { + "methods": ["classifyText", "classifyText", "classifyTextCallable"] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/gapic_metadata.json b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/gapic_metadata.json new file mode 100644 index 00000000..00621e6f --- /dev/null +++ b/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/gapic_metadata.json @@ -0,0 +1,36 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "java", + "protoPackage": "google.cloud.language.v1beta2", + "libraryPackage": "com.google.cloud.language.v1beta2", + "services": { + "LanguageService": { + "clients": { + "grpc": { + "libraryClient": "LanguageServiceClient", + "rpcs": { + "AnalyzeEntities": { + "methods": ["analyzeEntities", "analyzeEntities", "analyzeEntities", "analyzeEntitiesCallable"] + }, + "AnalyzeEntitySentiment": { + "methods": ["analyzeEntitySentiment", "analyzeEntitySentiment", "analyzeEntitySentiment", "analyzeEntitySentimentCallable"] + }, + "AnalyzeSentiment": { + "methods": ["analyzeSentiment", "analyzeSentiment", "analyzeSentiment", "analyzeSentimentCallable"] + }, + "AnalyzeSyntax": { + "methods": ["analyzeSyntax", "analyzeSyntax", "analyzeSyntax", "analyzeSyntaxCallable"] + }, + "AnnotateText": { + "methods": ["annotateText", "annotateText", "annotateText", "annotateTextCallable"] + }, + "ClassifyText": { + "methods": ["classifyText", "classifyText", "classifyTextCallable"] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/synth.metadata b/synth.metadata index e49fbe69..3a203285 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,23 +4,23 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-language.git", - "sha": "73e960956bd1f4a968eff1b3143b47f53b1d57dd" + "sha": "55d4321a5a10959eb3caf0f4fa9800ffb9fca2c9" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "e8bc4471a88ac5f60defe3ed436f517174e59ba0", - "internalRef": "357800868" + "sha": "af8f71dae961ee036a0ac52a1965270149a6b2c9", + "internalRef": "358516065" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "e8bc4471a88ac5f60defe3ed436f517174e59ba0", - "internalRef": "357800868" + "sha": "af8f71dae961ee036a0ac52a1965270149a6b2c9", + "internalRef": "358516065" } }, { @@ -120,6 +120,7 @@ "codecov.yaml", "google-cloud-language/src/main/java/com/google/cloud/language/v1/LanguageServiceClient.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1/LanguageServiceSettings.java", + "google-cloud-language/src/main/java/com/google/cloud/language/v1/gapic_metadata.json", "google-cloud-language/src/main/java/com/google/cloud/language/v1/package-info.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceCallableFactory.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceStub.java", @@ -127,6 +128,7 @@ "google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/LanguageServiceStubSettings.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceClient.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/LanguageServiceSettings.java", + "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/gapic_metadata.json", "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/package-info.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceCallableFactory.java", "google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceStub.java", From 18a513fdbb99b7bc6d44723a38748a42868c8be7 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Mon, 22 Feb 2021 20:36:11 +0000 Subject: [PATCH 25/25] chore(master): release 1.101.11 (#369) :robot: I have created a release \*beep\* \*boop\* --- ### [1.101.11](https://www.github.com/googleapis/java-language/compare/v1.101.10...v1.101.11) (2021-02-22) ### Documentation * generate sample code in the Java microgenerator ([#368](https://www.github.com/googleapis/java-language/issues/368)) ([85e966a](https://www.github.com/googleapis/java-language/commit/85e966a9a65aedde5b93173993cd06c94cf629aa)) ### Dependencies * update dependency com.google.cloud:google-cloud-shared-dependencies to v0.19.0 ([#380](https://www.github.com/googleapis/java-language/issues/380)) ([55d4321](https://www.github.com/googleapis/java-language/commit/55d4321a5a10959eb3caf0f4fa9800ffb9fca2c9)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 12 ++++++++++++ google-cloud-language-bom/pom.xml | 12 ++++++------ google-cloud-language/pom.xml | 4 ++-- grpc-google-cloud-language-v1/pom.xml | 4 ++-- grpc-google-cloud-language-v1beta2/pom.xml | 4 ++-- pom.xml | 12 ++++++------ proto-google-cloud-language-v1/pom.xml | 4 ++-- proto-google-cloud-language-v1beta2/pom.xml | 4 ++-- versions.txt | 10 +++++----- 9 files changed, 39 insertions(+), 27 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0de8190a..f62c7942 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,17 @@ # Changelog +### [1.101.11](https://www.github.com/googleapis/java-language/compare/v1.101.10...v1.101.11) (2021-02-22) + + +### Documentation + +* generate sample code in the Java microgenerator ([#368](https://www.github.com/googleapis/java-language/issues/368)) ([85e966a](https://www.github.com/googleapis/java-language/commit/85e966a9a65aedde5b93173993cd06c94cf629aa)) + + +### Dependencies + +* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.19.0 ([#380](https://www.github.com/googleapis/java-language/issues/380)) ([55d4321](https://www.github.com/googleapis/java-language/commit/55d4321a5a10959eb3caf0f4fa9800ffb9fca2c9)) + ### [1.101.10](https://www.github.com/googleapis/java-language/compare/v1.101.9...v1.101.10) (2021-01-14) diff --git a/google-cloud-language-bom/pom.xml b/google-cloud-language-bom/pom.xml index 6b207bda..dbdd6d75 100644 --- a/google-cloud-language-bom/pom.xml +++ b/google-cloud-language-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-language-bom -1.101.11-SNAPSHOT +1.101.11 pom com.google.cloud @@ -64,27 +64,27 @@com.google.api.grpc grpc-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 com.google.api.grpc grpc-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 com.google.api.grpc proto-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 com.google.cloud google-cloud-language -1.101.11-SNAPSHOT +1.101.11 diff --git a/google-cloud-language/pom.xml b/google-cloud-language/pom.xml index 1c451776..62280d59 100644 --- a/google-cloud-language/pom.xml +++ b/google-cloud-language/pom.xml @@ -3,7 +3,7 @@ com.google.api.grpc proto-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 4.0.0 com.google.cloud google-cloud-language -1.101.11-SNAPSHOT +1.101.11 jar Google Cloud Natural Language https://github.com/googleapis/java-language @@ -11,7 +11,7 @@com.google.cloud google-cloud-language-parent -1.101.11-SNAPSHOT +1.101.11 google-cloud-language diff --git a/grpc-google-cloud-language-v1/pom.xml b/grpc-google-cloud-language-v1/pom.xml index edb063e6..633b152f 100644 --- a/grpc-google-cloud-language-v1/pom.xml +++ b/grpc-google-cloud-language-v1/pom.xml @@ -4,13 +4,13 @@4.0.0 com.google.api.grpc grpc-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 grpc-google-cloud-language-v1 GRPC library for grpc-google-cloud-language-v1 com.google.cloud google-cloud-language-parent -1.101.11-SNAPSHOT +1.101.11 diff --git a/grpc-google-cloud-language-v1beta2/pom.xml b/grpc-google-cloud-language-v1beta2/pom.xml index 0add5914..fe7f2a98 100644 --- a/grpc-google-cloud-language-v1beta2/pom.xml +++ b/grpc-google-cloud-language-v1beta2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 grpc-google-cloud-language-v1beta2 GRPC library for grpc-google-cloud-language-v1beta2 com.google.cloud google-cloud-language-parent -1.101.11-SNAPSHOT +1.101.11 diff --git a/pom.xml b/pom.xml index 2c41d889..5ae311ca 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-language-parent pom -1.101.11-SNAPSHOT +1.101.11 Google Cloud Natural Language Parent https://github.com/googleapis/java-language @@ -70,27 +70,27 @@ com.google.api.grpc proto-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 com.google.api.grpc proto-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 com.google.api.grpc grpc-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 com.google.api.grpc grpc-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 com.google.cloud google-cloud-language -1.101.11-SNAPSHOT +1.101.11 diff --git a/proto-google-cloud-language-v1/pom.xml b/proto-google-cloud-language-v1/pom.xml index 9e0d99d5..bd20b866 100644 --- a/proto-google-cloud-language-v1/pom.xml +++ b/proto-google-cloud-language-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-language-v1 -1.83.11-SNAPSHOT +1.83.11 proto-google-cloud-language-v1 PROTO library for proto-google-cloud-language-v1 com.google.cloud google-cloud-language-parent -1.101.11-SNAPSHOT +1.101.11 diff --git a/proto-google-cloud-language-v1beta2/pom.xml b/proto-google-cloud-language-v1beta2/pom.xml index 7f3180ba..96b9ab81 100644 --- a/proto-google-cloud-language-v1beta2/pom.xml +++ b/proto-google-cloud-language-v1beta2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-language-v1beta2 -0.84.11-SNAPSHOT +0.84.11 proto-google-cloud-language-v1beta2 PROTO library for proto-google-cloud-language-v1beta2 com.google.cloud google-cloud-language-parent -1.101.11-SNAPSHOT +1.101.11 diff --git a/versions.txt b/versions.txt index 44f71924..632b54f2 100644 --- a/versions.txt +++ b/versions.txt @@ -1,8 +1,8 @@ # Format: # module:released-version:current-version -proto-google-cloud-language-v1:1.83.10:1.83.11-SNAPSHOT -proto-google-cloud-language-v1beta2:0.84.10:0.84.11-SNAPSHOT -grpc-google-cloud-language-v1:1.83.10:1.83.11-SNAPSHOT -grpc-google-cloud-language-v1beta2:0.84.10:0.84.11-SNAPSHOT -google-cloud-language:1.101.10:1.101.11-SNAPSHOT \ No newline at end of file +proto-google-cloud-language-v1:1.83.11:1.83.11 +proto-google-cloud-language-v1beta2:0.84.11:0.84.11 +grpc-google-cloud-language-v1:1.83.11:1.83.11 +grpc-google-cloud-language-v1beta2:0.84.11:0.84.11 +google-cloud-language:1.101.11:1.101.11 \ No newline at end of file