public static final class SpellingCorrection.Builder extends GeneratedMessageV3.Builder<SpellingCorrection.Builder> implements SpellingCorrectionOrBuilder
Spell check result.
Protobuf type google.cloud.talent.v4beta1.SpellingCorrection
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
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public SpellingCorrection.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public SpellingCorrection build()
Returns
buildPartial()
public SpellingCorrection buildPartial()
Returns
clear()
public SpellingCorrection.Builder clear()
Returns
Overrides
clearCorrected()
public SpellingCorrection.Builder clearCorrected()
Indicates if the query was corrected by the spell checker.
bool corrected = 1;
Returns
clearCorrectedHtml()
public SpellingCorrection.Builder clearCorrectedHtml()
Corrected output with html tags to highlight the corrected words.
Corrected words are called out with the "<b><i>...</i></b>" html tags.
For example, the user input query is "software enginear", where the second
word, "enginear," is incorrect. It should be "engineer". When spelling
correction is enabled, this value is
"software <b><i>engineer</i></b>".
string corrected_html = 3;
Returns
clearCorrectedText()
public SpellingCorrection.Builder clearCorrectedText()
Correction output consisting of the corrected keyword string.
string corrected_text = 2;
Returns
clearField(Descriptors.FieldDescriptor field)
public SpellingCorrection.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public SpellingCorrection.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clone()
public SpellingCorrection.Builder clone()
Returns
Overrides
getCorrected()
public boolean getCorrected()
Indicates if the query was corrected by the spell checker.
bool corrected = 1;
Returns
Type | Description |
boolean | The corrected.
|
getCorrectedHtml()
public String getCorrectedHtml()
Corrected output with html tags to highlight the corrected words.
Corrected words are called out with the "<b><i>...</i></b>" html tags.
For example, the user input query is "software enginear", where the second
word, "enginear," is incorrect. It should be "engineer". When spelling
correction is enabled, this value is
"software <b><i>engineer</i></b>".
string corrected_html = 3;
Returns
Type | Description |
String | The correctedHtml.
|
getCorrectedHtmlBytes()
public ByteString getCorrectedHtmlBytes()
Corrected output with html tags to highlight the corrected words.
Corrected words are called out with the "<b><i>...</i></b>" html tags.
For example, the user input query is "software enginear", where the second
word, "enginear," is incorrect. It should be "engineer". When spelling
correction is enabled, this value is
"software <b><i>engineer</i></b>".
string corrected_html = 3;
Returns
Type | Description |
ByteString | The bytes for correctedHtml.
|
getCorrectedText()
public String getCorrectedText()
Correction output consisting of the corrected keyword string.
string corrected_text = 2;
Returns
Type | Description |
String | The correctedText.
|
getCorrectedTextBytes()
public ByteString getCorrectedTextBytes()
Correction output consisting of the corrected keyword string.
string corrected_text = 2;
Returns
Type | Description |
ByteString | The bytes for correctedText.
|
getDefaultInstanceForType()
public SpellingCorrection getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(SpellingCorrection other)
public SpellingCorrection.Builder mergeFrom(SpellingCorrection other)
Parameter
Returns
public SpellingCorrection.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public SpellingCorrection.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final SpellingCorrection.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setCorrected(boolean value)
public SpellingCorrection.Builder setCorrected(boolean value)
Indicates if the query was corrected by the spell checker.
bool corrected = 1;
Parameter
Name | Description |
value | boolean
The corrected to set.
|
Returns
setCorrectedHtml(String value)
public SpellingCorrection.Builder setCorrectedHtml(String value)
Corrected output with html tags to highlight the corrected words.
Corrected words are called out with the "<b><i>...</i></b>" html tags.
For example, the user input query is "software enginear", where the second
word, "enginear," is incorrect. It should be "engineer". When spelling
correction is enabled, this value is
"software <b><i>engineer</i></b>".
string corrected_html = 3;
Parameter
Name | Description |
value | String
The correctedHtml to set.
|
Returns
setCorrectedHtmlBytes(ByteString value)
public SpellingCorrection.Builder setCorrectedHtmlBytes(ByteString value)
Corrected output with html tags to highlight the corrected words.
Corrected words are called out with the "<b><i>...</i></b>" html tags.
For example, the user input query is "software enginear", where the second
word, "enginear," is incorrect. It should be "engineer". When spelling
correction is enabled, this value is
"software <b><i>engineer</i></b>".
string corrected_html = 3;
Parameter
Name | Description |
value | ByteString
The bytes for correctedHtml to set.
|
Returns
setCorrectedText(String value)
public SpellingCorrection.Builder setCorrectedText(String value)
Correction output consisting of the corrected keyword string.
string corrected_text = 2;
Parameter
Name | Description |
value | String
The correctedText to set.
|
Returns
setCorrectedTextBytes(ByteString value)
public SpellingCorrection.Builder setCorrectedTextBytes(ByteString value)
Correction output consisting of the corrected keyword string.
string corrected_text = 2;
Parameter
Name | Description |
value | ByteString
The bytes for correctedText to set.
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public SpellingCorrection.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public SpellingCorrection.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final SpellingCorrection.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides