- 2.77.0 (latest)
- 2.76.0
- 2.75.0
- 2.74.0
- 2.73.0
- 2.71.0
- 2.69.0
- 2.68.0
- 2.65.0
- 2.64.0
- 2.63.0
- 2.61.0
- 2.60.0
- 2.59.0
- 2.58.0
- 2.57.0
- 2.56.0
- 2.55.0
- 2.54.0
- 2.53.0
- 2.52.0
- 2.50.0
- 2.49.0
- 2.48.0
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.0
- 2.43.0
- 2.42.0
- 2.41.0
- 2.40.0
- 2.38.0
- 2.37.0
- 2.36.0
- 2.35.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.31.0
- 2.30.0
- 2.29.0
- 2.28.0
- 2.25.0
- 2.24.0
- 2.23.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.0
- 2.17.0
- 2.16.0
- 2.15.0
- 2.14.0
- 2.13.0
- 2.12.0
- 2.10.0
- 2.9.0
- 2.8.0
- 2.7.0
- 2.6.0
- 2.5.0
- 2.4.1
- 2.3.4
- 2.2.0
- 2.1.10
public static final class AnalyzeSentimentResponse.Builder extends GeneratedMessageV3.Builder<AnalyzeSentimentResponse.Builder> implements AnalyzeSentimentResponseOrBuilderThe sentiment analysis response message.
Protobuf type google.cloud.language.v2.AnalyzeSentimentResponse
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > AnalyzeSentimentResponse.BuilderImplements
AnalyzeSentimentResponseOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
addAllSentences(Iterable<? extends Sentence> values)
public AnalyzeSentimentResponse.Builder addAllSentences(Iterable<? extends Sentence> values)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
values |
Iterable<? extends com.google.cloud.language.v2.Sentence> |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public AnalyzeSentimentResponse.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addSentences(Sentence value)
public AnalyzeSentimentResponse.Builder addSentences(Sentence value)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
value |
Sentence |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addSentences(Sentence.Builder builderForValue)
public AnalyzeSentimentResponse.Builder addSentences(Sentence.Builder builderForValue)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
Sentence.Builder |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addSentences(int index, Sentence value)
public AnalyzeSentimentResponse.Builder addSentences(int index, Sentence value)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
value |
Sentence |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addSentences(int index, Sentence.Builder builderForValue)
public AnalyzeSentimentResponse.Builder addSentences(int index, Sentence.Builder builderForValue)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
builderForValue |
Sentence.Builder |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
addSentencesBuilder()
public Sentence.Builder addSentencesBuilder()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
Sentence.Builder |
|
addSentencesBuilder(int index)
public Sentence.Builder addSentencesBuilder(int index)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
Sentence.Builder |
|
build()
public AnalyzeSentimentResponse build()| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse |
|
buildPartial()
public AnalyzeSentimentResponse buildPartial()| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse |
|
clear()
public AnalyzeSentimentResponse.Builder clear()| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
clearDocumentSentiment()
public AnalyzeSentimentResponse.Builder clearDocumentSentiment()The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
clearField(Descriptors.FieldDescriptor field)
public AnalyzeSentimentResponse.Builder clearField(Descriptors.FieldDescriptor field)| Parameter | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
clearLanguageCode()
public AnalyzeSentimentResponse.Builder clearLanguageCode()The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language. See [Document.language][] field for more details.
string language_code = 2;
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
This builder for chaining. |
clearLanguageSupported()
public AnalyzeSentimentResponse.Builder clearLanguageSupported()Whether the language is officially supported. The API may still return a response when the language is not supported, but it is on a best effort basis.
bool language_supported = 4;
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public AnalyzeSentimentResponse.Builder clearOneof(Descriptors.OneofDescriptor oneof)| Parameter | |
|---|---|
| Name | Description |
oneof |
OneofDescriptor |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
clearSentences()
public AnalyzeSentimentResponse.Builder clearSentences()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
clone()
public AnalyzeSentimentResponse.Builder clone()| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
getDefaultInstanceForType()
public AnalyzeSentimentResponse getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getDocumentSentiment()
public Sentiment getDocumentSentiment()The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Returns | |
|---|---|
| Type | Description |
Sentiment |
The documentSentiment. |
getDocumentSentimentBuilder()
public Sentiment.Builder getDocumentSentimentBuilder()The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Returns | |
|---|---|
| Type | Description |
Sentiment.Builder |
|
getDocumentSentimentOrBuilder()
public SentimentOrBuilder getDocumentSentimentOrBuilder()The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Returns | |
|---|---|
| Type | Description |
SentimentOrBuilder |
|
getLanguageCode()
public String getLanguageCode()The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language. See [Document.language][] field for more details.
string language_code = 2;
| Returns | |
|---|---|
| Type | Description |
String |
The languageCode. |
getLanguageCodeBytes()
public ByteString getLanguageCodeBytes()The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language. See [Document.language][] field for more details.
string language_code = 2;
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for languageCode. |
getLanguageSupported()
public boolean getLanguageSupported()Whether the language is officially supported. The API may still return a response when the language is not supported, but it is on a best effort basis.
bool language_supported = 4;
| Returns | |
|---|---|
| Type | Description |
boolean |
The languageSupported. |
getSentences(int index)
public Sentence getSentences(int index)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
Sentence |
|
getSentencesBuilder(int index)
public Sentence.Builder getSentencesBuilder(int index)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
Sentence.Builder |
|
getSentencesBuilderList()
public List<Sentence.Builder> getSentencesBuilderList()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
List<Builder> |
|
getSentencesCount()
public int getSentencesCount()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
int |
|
getSentencesList()
public List<Sentence> getSentencesList()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
List<Sentence> |
|
getSentencesOrBuilder(int index)
public SentenceOrBuilder getSentencesOrBuilder(int index)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
SentenceOrBuilder |
|
getSentencesOrBuilderList()
public List<? extends SentenceOrBuilder> getSentencesOrBuilderList()The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Returns | |
|---|---|
| Type | Description |
List<? extends com.google.cloud.language.v2.SentenceOrBuilder> |
|
hasDocumentSentiment()
public boolean hasDocumentSentiment()The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the documentSentiment field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeDocumentSentiment(Sentiment value)
public AnalyzeSentimentResponse.Builder mergeDocumentSentiment(Sentiment value)The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
Sentiment |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
mergeFrom(AnalyzeSentimentResponse other)
public AnalyzeSentimentResponse.Builder mergeFrom(AnalyzeSentimentResponse other)| Parameter | |
|---|---|
| Name | Description |
other |
AnalyzeSentimentResponse |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public AnalyzeSentimentResponse.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public AnalyzeSentimentResponse.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
mergeUnknownFields(UnknownFieldSet unknownFields)
public final AnalyzeSentimentResponse.Builder mergeUnknownFields(UnknownFieldSet unknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
removeSentences(int index)
public AnalyzeSentimentResponse.Builder removeSentences(int index)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setDocumentSentiment(Sentiment value)
public AnalyzeSentimentResponse.Builder setDocumentSentiment(Sentiment value)The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
Sentiment |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setDocumentSentiment(Sentiment.Builder builderForValue)
public AnalyzeSentimentResponse.Builder setDocumentSentiment(Sentiment.Builder builderForValue)The overall sentiment of the input document.
.google.cloud.language.v2.Sentiment document_sentiment = 1;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
Sentiment.Builder |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setField(Descriptors.FieldDescriptor field, Object value)
public AnalyzeSentimentResponse.Builder setField(Descriptors.FieldDescriptor field, Object value)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setLanguageCode(String value)
public AnalyzeSentimentResponse.Builder setLanguageCode(String value)The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language. See [Document.language][] field for more details.
string language_code = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe languageCode to set. |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
This builder for chaining. |
setLanguageCodeBytes(ByteString value)
public AnalyzeSentimentResponse.Builder setLanguageCodeBytes(ByteString value)The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language. See [Document.language][] field for more details.
string language_code = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for languageCode to set. |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
This builder for chaining. |
setLanguageSupported(boolean value)
public AnalyzeSentimentResponse.Builder setLanguageSupported(boolean value)Whether the language is officially supported. The API may still return a response when the language is not supported, but it is on a best effort basis.
bool language_supported = 4;
| Parameter | |
|---|---|
| Name | Description |
value |
booleanThe languageSupported to set. |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public AnalyzeSentimentResponse.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
index |
int |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setSentences(int index, Sentence value)
public AnalyzeSentimentResponse.Builder setSentences(int index, Sentence value)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
value |
Sentence |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setSentences(int index, Sentence.Builder builderForValue)
public AnalyzeSentimentResponse.Builder setSentences(int index, Sentence.Builder builderForValue)The sentiment for all the sentences in the document.
repeated .google.cloud.language.v2.Sentence sentences = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
builderForValue |
Sentence.Builder |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|
setUnknownFields(UnknownFieldSet unknownFields)
public final AnalyzeSentimentResponse.Builder setUnknownFields(UnknownFieldSet unknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AnalyzeSentimentResponse.Builder |
|