@java.lang.Override public Builder newBuilderForType() { return newBuilder(); }
/** * Analyzes the sentiment of the provided text. * * <p>Sample code: * * <pre><code> * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * Document document = Document.newBuilder().build(); * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); * } * </code></pre> * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final AnalyzeSentimentResponse analyzeSentiment(Document document) { AnalyzeSentimentRequest request = AnalyzeSentimentRequest.newBuilder().setDocument(document).build(); return analyzeSentiment(request); }
@java.lang.Override public Builder newBuilderForType() { return newBuilder(); }
/** * Analyzes the sentiment of the provided text. * * <p>Sample code: * * <pre><code> * try (LanguageServiceClient languageServiceClient = LanguageServiceClient.create()) { * Document document = Document.newBuilder().build(); * AnalyzeSentimentResponse response = languageServiceClient.analyzeSentiment(document); * } * </code></pre> * * @param document Input document. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final AnalyzeSentimentResponse analyzeSentiment(Document document) { AnalyzeSentimentRequest request = AnalyzeSentimentRequest.newBuilder().setDocument(document).build(); return analyzeSentiment(request); }