public static final class QAResult.Builder extends GeneratedMessageV3.Builder<QAResult.Builder> implements QAResultOrBuilder
Additional result info for the question-answering feature.
Protobuf type google.cloud.contentwarehouse.v1.QAResult
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addAllHighlights(Iterable<? extends QAResult.Highlight> values)
public QAResult.Builder addAllHighlights(Iterable<? extends QAResult.Highlight> values)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Name | Description |
values | Iterable<? extends com.google.cloud.contentwarehouse.v1.QAResult.Highlight>
|
Returns
addHighlights(QAResult.Highlight value)
public QAResult.Builder addHighlights(QAResult.Highlight value)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
addHighlights(QAResult.Highlight.Builder builderForValue)
public QAResult.Builder addHighlights(QAResult.Highlight.Builder builderForValue)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
addHighlights(int index, QAResult.Highlight value)
public QAResult.Builder addHighlights(int index, QAResult.Highlight value)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameters
Returns
addHighlights(int index, QAResult.Highlight.Builder builderForValue)
public QAResult.Builder addHighlights(int index, QAResult.Highlight.Builder builderForValue)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameters
Returns
addHighlightsBuilder()
public QAResult.Highlight.Builder addHighlightsBuilder()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
addHighlightsBuilder(int index)
public QAResult.Highlight.Builder addHighlightsBuilder(int index)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public QAResult.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
Returns
buildPartial()
public QAResult buildPartial()
Returns
clear()
public QAResult.Builder clear()
Returns
Overrides
clearConfidenceScore()
public QAResult.Builder clearConfidenceScore()
The calibrated confidence score for this document, in the range
[0., 1.]. This represents the confidence level for whether the returned
document and snippet answers the user's query.
float confidence_score = 2;
Returns
clearField(Descriptors.FieldDescriptor field)
public QAResult.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearHighlights()
public QAResult.Builder clearHighlights()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public QAResult.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clone()
public QAResult.Builder clone()
Returns
Overrides
getConfidenceScore()
public float getConfidenceScore()
The calibrated confidence score for this document, in the range
[0., 1.]. This represents the confidence level for whether the returned
document and snippet answers the user's query.
float confidence_score = 2;
Returns
Type | Description |
float | The confidenceScore.
|
getDefaultInstanceForType()
public QAResult getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getHighlights(int index)
public QAResult.Highlight getHighlights(int index)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
getHighlightsBuilder(int index)
public QAResult.Highlight.Builder getHighlightsBuilder(int index)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
getHighlightsBuilderList()
public List<QAResult.Highlight.Builder> getHighlightsBuilderList()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
getHighlightsCount()
public int getHighlightsCount()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
getHighlightsList()
public List<QAResult.Highlight> getHighlightsList()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
getHighlightsOrBuilder(int index)
public QAResult.HighlightOrBuilder getHighlightsOrBuilder(int index)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
getHighlightsOrBuilderList()
public List<? extends QAResult.HighlightOrBuilder> getHighlightsOrBuilderList()
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Returns
Type | Description |
List<? extends com.google.cloud.contentwarehouse.v1.QAResult.HighlightOrBuilder> | |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(QAResult other)
public QAResult.Builder mergeFrom(QAResult other)
Parameter
Returns
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public QAResult.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public QAResult.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final QAResult.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
removeHighlights(int index)
public QAResult.Builder removeHighlights(int index)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameter
Returns
setConfidenceScore(float value)
public QAResult.Builder setConfidenceScore(float value)
The calibrated confidence score for this document, in the range
[0., 1.]. This represents the confidence level for whether the returned
document and snippet answers the user's query.
float confidence_score = 2;
Parameter
Name | Description |
value | float
The confidenceScore to set.
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public QAResult.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setHighlights(int index, QAResult.Highlight value)
public QAResult.Builder setHighlights(int index, QAResult.Highlight value)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameters
Returns
setHighlights(int index, QAResult.Highlight.Builder builderForValue)
public QAResult.Builder setHighlights(int index, QAResult.Highlight.Builder builderForValue)
Highlighted sections in the snippet.
repeated .google.cloud.contentwarehouse.v1.QAResult.Highlight highlights = 1;
Parameters
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public QAResult.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final QAResult.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides