Class RankingRecord.Builder (0.40.0)

public static final class RankingRecord.Builder extends GeneratedMessageV3.Builder<RankingRecord.Builder> implements RankingRecordOrBuilder

Record message for RankService.Rank method.

Protobuf type google.cloud.discoveryengine.v1beta.RankingRecord

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public RankingRecord.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RankingRecord.Builder
Overrides

build()

public RankingRecord build()
Returns
Type Description
RankingRecord

buildPartial()

public RankingRecord buildPartial()
Returns
Type Description
RankingRecord

clear()

public RankingRecord.Builder clear()
Returns
Type Description
RankingRecord.Builder
Overrides

clearContent()

public RankingRecord.Builder clearContent()

The content of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string content = 3;

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public RankingRecord.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
RankingRecord.Builder
Overrides

clearId()

public RankingRecord.Builder clearId()

The unique ID to represent the record.

string id = 1;

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public RankingRecord.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
RankingRecord.Builder
Overrides

clearScore()

public RankingRecord.Builder clearScore()

The score of this record based on the given query and selected model.

float score = 4;

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

clearTitle()

public RankingRecord.Builder clearTitle()

The title of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string title = 2;

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

clone()

public RankingRecord.Builder clone()
Returns
Type Description
RankingRecord.Builder
Overrides

getContent()

public String getContent()

The content of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string content = 3;

Returns
Type Description
String

The content.

getContentBytes()

public ByteString getContentBytes()

The content of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string content = 3;

Returns
Type Description
ByteString

The bytes for content.

getDefaultInstanceForType()

public RankingRecord getDefaultInstanceForType()
Returns
Type Description
RankingRecord

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getId()

public String getId()

The unique ID to represent the record.

string id = 1;

Returns
Type Description
String

The id.

getIdBytes()

public ByteString getIdBytes()

The unique ID to represent the record.

string id = 1;

Returns
Type Description
ByteString

The bytes for id.

getScore()

public float getScore()

The score of this record based on the given query and selected model.

float score = 4;

Returns
Type Description
float

The score.

getTitle()

public String getTitle()

The title of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string title = 2;

Returns
Type Description
String

The title.

getTitleBytes()

public ByteString getTitleBytes()

The title of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string title = 2;

Returns
Type Description
ByteString

The bytes for title.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(RankingRecord other)

public RankingRecord.Builder mergeFrom(RankingRecord other)
Parameter
Name Description
other RankingRecord
Returns
Type Description
RankingRecord.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public RankingRecord.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
RankingRecord.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public RankingRecord.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
RankingRecord.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final RankingRecord.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RankingRecord.Builder
Overrides

setContent(String value)

public RankingRecord.Builder setContent(String value)

The content of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string content = 3;

Parameter
Name Description
value String

The content to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setContentBytes(ByteString value)

public RankingRecord.Builder setContentBytes(ByteString value)

The content of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string content = 3;

Parameter
Name Description
value ByteString

The bytes for content to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public RankingRecord.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RankingRecord.Builder
Overrides

setId(String value)

public RankingRecord.Builder setId(String value)

The unique ID to represent the record.

string id = 1;

Parameter
Name Description
value String

The id to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setIdBytes(ByteString value)

public RankingRecord.Builder setIdBytes(ByteString value)

The unique ID to represent the record.

string id = 1;

Parameter
Name Description
value ByteString

The bytes for id to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

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

public RankingRecord.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
RankingRecord.Builder
Overrides

setScore(float value)

public RankingRecord.Builder setScore(float value)

The score of this record based on the given query and selected model.

float score = 4;

Parameter
Name Description
value float

The score to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setTitle(String value)

public RankingRecord.Builder setTitle(String value)

The title of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string title = 2;

Parameter
Name Description
value String

The title to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setTitleBytes(ByteString value)

public RankingRecord.Builder setTitleBytes(ByteString value)

The title of the record. Empty by default. At least one of title or content should be set otherwise an INVALID_ARGUMENT error is thrown.

string title = 2;

Parameter
Name Description
value ByteString

The bytes for title to set.

Returns
Type Description
RankingRecord.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final RankingRecord.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RankingRecord.Builder
Overrides