Class SearchResponse.SearchResult (0.36.0)

public static final class SearchResponse.SearchResult extends GeneratedMessageV3 implements SearchResponse.SearchResultOrBuilder

Represents the search results.

Protobuf type google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult

Static Fields

DOCUMENT_FIELD_NUMBER

public static final int DOCUMENT_FIELD_NUMBER
Field Value
TypeDescription
int

ID_FIELD_NUMBER

public static final int ID_FIELD_NUMBER
Field Value
TypeDescription
int

MODEL_SCORES_FIELD_NUMBER

public static final int MODEL_SCORES_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static SearchResponse.SearchResult getDefaultInstance()
Returns
TypeDescription
SearchResponse.SearchResult

getDescriptor()

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

newBuilder()

public static SearchResponse.SearchResult.Builder newBuilder()
Returns
TypeDescription
SearchResponse.SearchResult.Builder

newBuilder(SearchResponse.SearchResult prototype)

public static SearchResponse.SearchResult.Builder newBuilder(SearchResponse.SearchResult prototype)
Parameter
NameDescription
prototypeSearchResponse.SearchResult
Returns
TypeDescription
SearchResponse.SearchResult.Builder

parseDelimitedFrom(InputStream input)

public static SearchResponse.SearchResult parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static SearchResponse.SearchResult parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static SearchResponse.SearchResult parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static SearchResponse.SearchResult parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static SearchResponse.SearchResult parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static SearchResponse.SearchResult parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static SearchResponse.SearchResult parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchResponse.SearchResult
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<SearchResponse.SearchResult> parser()
Returns
TypeDescription
Parser<SearchResult>

Methods

containsModelScores(String key)

public boolean containsModelScores(String key)

Google provided available scores.

map<string, .google.cloud.discoveryengine.v1beta.DoubleList> model_scores = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public SearchResponse.SearchResult getDefaultInstanceForType()
Returns
TypeDescription
SearchResponse.SearchResult

getDocument()

public Document getDocument()

The document data snippet in the search response. Only fields that are marked as retrievable are populated.

.google.cloud.discoveryengine.v1beta.Document document = 2;

Returns
TypeDescription
Document

The document.

getDocumentOrBuilder()

public DocumentOrBuilder getDocumentOrBuilder()

The document data snippet in the search response. Only fields that are marked as retrievable are populated.

.google.cloud.discoveryengine.v1beta.Document document = 2;

Returns
TypeDescription
DocumentOrBuilder

getId()

public String getId()

Document.id of the searched Document.

string id = 1;

Returns
TypeDescription
String

The id.

getIdBytes()

public ByteString getIdBytes()

Document.id of the searched Document.

string id = 1;

Returns
TypeDescription
ByteString

The bytes for id.

getModelScores() (deprecated)

public Map<String,DoubleList> getModelScores()

Use #getModelScoresMap() instead.

Returns
TypeDescription
Map<String,DoubleList>

getModelScoresCount()

public int getModelScoresCount()

Google provided available scores.

map<string, .google.cloud.discoveryengine.v1beta.DoubleList> model_scores = 4;

Returns
TypeDescription
int

getModelScoresMap()

public Map<String,DoubleList> getModelScoresMap()

Google provided available scores.

map<string, .google.cloud.discoveryengine.v1beta.DoubleList> model_scores = 4;

Returns
TypeDescription
Map<String,DoubleList>

getModelScoresOrDefault(String key, DoubleList defaultValue)

public DoubleList getModelScoresOrDefault(String key, DoubleList defaultValue)

Google provided available scores.

map<string, .google.cloud.discoveryengine.v1beta.DoubleList> model_scores = 4;

Parameters
NameDescription
keyString
defaultValueDoubleList
Returns
TypeDescription
DoubleList

getModelScoresOrThrow(String key)

public DoubleList getModelScoresOrThrow(String key)

Google provided available scores.

map<string, .google.cloud.discoveryengine.v1beta.DoubleList> model_scores = 4;

Parameter
NameDescription
keyString
Returns
TypeDescription
DoubleList

getParserForType()

public Parser<SearchResponse.SearchResult> getParserForType()
Returns
TypeDescription
Parser<SearchResult>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

hasDocument()

public boolean hasDocument()

The document data snippet in the search response. Only fields that are marked as retrievable are populated.

.google.cloud.discoveryengine.v1beta.Document document = 2;

Returns
TypeDescription
boolean

Whether the document field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public SearchResponse.SearchResult.Builder newBuilderForType()
Returns
TypeDescription
SearchResponse.SearchResult.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected SearchResponse.SearchResult.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
SearchResponse.SearchResult.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public SearchResponse.SearchResult.Builder toBuilder()
Returns
TypeDescription
SearchResponse.SearchResult.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException