Class SpellingCorrection.Builder

public static final class SpellingCorrection.Builder extends GeneratedMessageV3.Builder<SpellingCorrection.Builder> implements SpellingCorrectionOrBuilder

Spell check result.

Protobuf type google.cloud.talent.v4.SpellingCorrection

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SpellingCorrection.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

build()

public SpellingCorrection build()
Returns
TypeDescription
SpellingCorrection

buildPartial()

public SpellingCorrection buildPartial()
Returns
TypeDescription
SpellingCorrection

clear()

public SpellingCorrection.Builder clear()
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

clearCorrected()

public SpellingCorrection.Builder clearCorrected()

Indicates if the query was corrected by the spell checker.

bool corrected = 1;

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

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
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

clearCorrectedText()

public SpellingCorrection.Builder clearCorrectedText()

Correction output consisting of the corrected keyword string.

string corrected_text = 2;

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public SpellingCorrection.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public SpellingCorrection.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

clone()

public SpellingCorrection.Builder clone()
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

getCorrected()

public boolean getCorrected()

Indicates if the query was corrected by the spell checker.

bool corrected = 1;

Returns
TypeDescription
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
TypeDescription
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
TypeDescription
ByteString

The bytes for correctedHtml.

getCorrectedText()

public String getCorrectedText()

Correction output consisting of the corrected keyword string.

string corrected_text = 2;

Returns
TypeDescription
String

The correctedText.

getCorrectedTextBytes()

public ByteString getCorrectedTextBytes()

Correction output consisting of the corrected keyword string.

string corrected_text = 2;

Returns
TypeDescription
ByteString

The bytes for correctedText.

getDefaultInstanceForType()

public SpellingCorrection getDefaultInstanceForType()
Returns
TypeDescription
SpellingCorrection

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(SpellingCorrection other)

public SpellingCorrection.Builder mergeFrom(SpellingCorrection other)
Parameter
NameDescription
otherSpellingCorrection
Returns
TypeDescription
SpellingCorrection.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SpellingCorrection.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SpellingCorrection.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public SpellingCorrection.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SpellingCorrection.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

setCorrected(boolean value)

public SpellingCorrection.Builder setCorrected(boolean value)

Indicates if the query was corrected by the spell checker.

bool corrected = 1;

Parameter
NameDescription
valueboolean

The corrected to set.

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

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
NameDescription
valueString

The correctedHtml to set.

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

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
NameDescription
valueByteString

The bytes for correctedHtml to set.

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

setCorrectedText(String value)

public SpellingCorrection.Builder setCorrectedText(String value)

Correction output consisting of the corrected keyword string.

string corrected_text = 2;

Parameter
NameDescription
valueString

The correctedText to set.

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

setCorrectedTextBytes(ByteString value)

public SpellingCorrection.Builder setCorrectedTextBytes(ByteString value)

Correction output consisting of the corrected keyword string.

string corrected_text = 2;

Parameter
NameDescription
valueByteString

The bytes for correctedText to set.

Returns
TypeDescription
SpellingCorrection.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public SpellingCorrection.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public SpellingCorrection.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
SpellingCorrection.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SpellingCorrection.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SpellingCorrection.Builder
Overrides