Class NearestNeighbors.Builder (3.42.0)

public static final class NearestNeighbors.Builder extends GeneratedMessageV3.Builder<NearestNeighbors.Builder> implements NearestNeighborsOrBuilder

Nearest neighbors for one query.

Protobuf type google.cloud.aiplatform.v1.NearestNeighbors

Static Methods

getDescriptor()

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

Methods

addAllNeighbors(Iterable<? extends NearestNeighbors.Neighbor> values)

public NearestNeighbors.Builder addAllNeighbors(Iterable<? extends NearestNeighbors.Neighbor> values)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
values Iterable<? extends com.google.cloud.aiplatform.v1.NearestNeighbors.Neighbor>
Returns
Type Description
NearestNeighbors.Builder

addNeighbors(NearestNeighbors.Neighbor value)

public NearestNeighbors.Builder addNeighbors(NearestNeighbors.Neighbor value)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
value NearestNeighbors.Neighbor
Returns
Type Description
NearestNeighbors.Builder

addNeighbors(NearestNeighbors.Neighbor.Builder builderForValue)

public NearestNeighbors.Builder addNeighbors(NearestNeighbors.Neighbor.Builder builderForValue)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
builderForValue NearestNeighbors.Neighbor.Builder
Returns
Type Description
NearestNeighbors.Builder

addNeighbors(int index, NearestNeighbors.Neighbor value)

public NearestNeighbors.Builder addNeighbors(int index, NearestNeighbors.Neighbor value)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameters
Name Description
index int
value NearestNeighbors.Neighbor
Returns
Type Description
NearestNeighbors.Builder

addNeighbors(int index, NearestNeighbors.Neighbor.Builder builderForValue)

public NearestNeighbors.Builder addNeighbors(int index, NearestNeighbors.Neighbor.Builder builderForValue)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameters
Name Description
index int
builderForValue NearestNeighbors.Neighbor.Builder
Returns
Type Description
NearestNeighbors.Builder

addNeighborsBuilder()

public NearestNeighbors.Neighbor.Builder addNeighborsBuilder()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
NearestNeighbors.Neighbor.Builder

addNeighborsBuilder(int index)

public NearestNeighbors.Neighbor.Builder addNeighborsBuilder(int index)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
index int
Returns
Type Description
NearestNeighbors.Neighbor.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public NearestNeighbors build()
Returns
Type Description
NearestNeighbors

buildPartial()

public NearestNeighbors buildPartial()
Returns
Type Description
NearestNeighbors

clear()

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

clearField(Descriptors.FieldDescriptor field)

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

clearNeighbors()

public NearestNeighbors.Builder clearNeighbors()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
NearestNeighbors.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getDefaultInstanceForType()

public NearestNeighbors getDefaultInstanceForType()
Returns
Type Description
NearestNeighbors

getDescriptorForType()

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

getNeighbors(int index)

public NearestNeighbors.Neighbor getNeighbors(int index)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
index int
Returns
Type Description
NearestNeighbors.Neighbor

getNeighborsBuilder(int index)

public NearestNeighbors.Neighbor.Builder getNeighborsBuilder(int index)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
index int
Returns
Type Description
NearestNeighbors.Neighbor.Builder

getNeighborsBuilderList()

public List<NearestNeighbors.Neighbor.Builder> getNeighborsBuilderList()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
List<Builder>

getNeighborsCount()

public int getNeighborsCount()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
int

getNeighborsList()

public List<NearestNeighbors.Neighbor> getNeighborsList()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
List<Neighbor>

getNeighborsOrBuilder(int index)

public NearestNeighbors.NeighborOrBuilder getNeighborsOrBuilder(int index)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
index int
Returns
Type Description
NearestNeighbors.NeighborOrBuilder

getNeighborsOrBuilderList()

public List<? extends NearestNeighbors.NeighborOrBuilder> getNeighborsOrBuilderList()

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Returns
Type Description
List<? extends com.google.cloud.aiplatform.v1.NearestNeighbors.NeighborOrBuilder>

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(NearestNeighbors other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeNeighbors(int index)

public NearestNeighbors.Builder removeNeighbors(int index)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameter
Name Description
index int
Returns
Type Description
NearestNeighbors.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setNeighbors(int index, NearestNeighbors.Neighbor value)

public NearestNeighbors.Builder setNeighbors(int index, NearestNeighbors.Neighbor value)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameters
Name Description
index int
value NearestNeighbors.Neighbor
Returns
Type Description
NearestNeighbors.Builder

setNeighbors(int index, NearestNeighbors.Neighbor.Builder builderForValue)

public NearestNeighbors.Builder setNeighbors(int index, NearestNeighbors.Neighbor.Builder builderForValue)

All its neighbors.

repeated .google.cloud.aiplatform.v1.NearestNeighbors.Neighbor neighbors = 1;

Parameters
Name Description
index int
builderForValue NearestNeighbors.Neighbor.Builder
Returns
Type Description
NearestNeighbors.Builder

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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