Class ListRecommendationsResponse.Builder (2.56.0)

public static final class ListRecommendationsResponse.Builder extends GeneratedMessageV3.Builder<ListRecommendationsResponse.Builder> implements ListRecommendationsResponseOrBuilder

Response to the ListRecommendations method.

Protobuf type google.cloud.recommender.v1.ListRecommendationsResponse

Static Methods

getDescriptor()

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

Methods

addAllRecommendations(Iterable<? extends Recommendation> values)

public ListRecommendationsResponse.Builder addAllRecommendations(Iterable<? extends Recommendation> values)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
values Iterable<? extends com.google.cloud.recommender.v1.Recommendation>
Returns
Type Description
ListRecommendationsResponse.Builder

addRecommendations(Recommendation value)

public ListRecommendationsResponse.Builder addRecommendations(Recommendation value)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
value Recommendation
Returns
Type Description
ListRecommendationsResponse.Builder

addRecommendations(Recommendation.Builder builderForValue)

public ListRecommendationsResponse.Builder addRecommendations(Recommendation.Builder builderForValue)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
builderForValue Recommendation.Builder
Returns
Type Description
ListRecommendationsResponse.Builder

addRecommendations(int index, Recommendation value)

public ListRecommendationsResponse.Builder addRecommendations(int index, Recommendation value)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameters
Name Description
index int
value Recommendation
Returns
Type Description
ListRecommendationsResponse.Builder

addRecommendations(int index, Recommendation.Builder builderForValue)

public ListRecommendationsResponse.Builder addRecommendations(int index, Recommendation.Builder builderForValue)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameters
Name Description
index int
builderForValue Recommendation.Builder
Returns
Type Description
ListRecommendationsResponse.Builder

addRecommendationsBuilder()

public Recommendation.Builder addRecommendationsBuilder()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
Recommendation.Builder

addRecommendationsBuilder(int index)

public Recommendation.Builder addRecommendationsBuilder(int index)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
index int
Returns
Type Description
Recommendation.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public ListRecommendationsResponse build()
Returns
Type Description
ListRecommendationsResponse

buildPartial()

public ListRecommendationsResponse buildPartial()
Returns
Type Description
ListRecommendationsResponse

clear()

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

clearField(Descriptors.FieldDescriptor field)

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

clearNextPageToken()

public ListRecommendationsResponse.Builder clearNextPageToken()

A token that can be used to request the next page of results. This field is empty if there are no additional results.

string next_page_token = 2;

Returns
Type Description
ListRecommendationsResponse.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearRecommendations()

public ListRecommendationsResponse.Builder clearRecommendations()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
ListRecommendationsResponse.Builder

clone()

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

getDefaultInstanceForType()

public ListRecommendationsResponse getDefaultInstanceForType()
Returns
Type Description
ListRecommendationsResponse

getDescriptorForType()

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

getNextPageToken()

public String getNextPageToken()

A token that can be used to request the next page of results. This field is empty if there are no additional results.

string next_page_token = 2;

Returns
Type Description
String

The nextPageToken.

getNextPageTokenBytes()

public ByteString getNextPageTokenBytes()

A token that can be used to request the next page of results. This field is empty if there are no additional results.

string next_page_token = 2;

Returns
Type Description
ByteString

The bytes for nextPageToken.

getRecommendations(int index)

public Recommendation getRecommendations(int index)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
index int
Returns
Type Description
Recommendation

getRecommendationsBuilder(int index)

public Recommendation.Builder getRecommendationsBuilder(int index)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
index int
Returns
Type Description
Recommendation.Builder

getRecommendationsBuilderList()

public List<Recommendation.Builder> getRecommendationsBuilderList()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
List<Builder>

getRecommendationsCount()

public int getRecommendationsCount()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
int

getRecommendationsList()

public List<Recommendation> getRecommendationsList()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
List<Recommendation>

getRecommendationsOrBuilder(int index)

public RecommendationOrBuilder getRecommendationsOrBuilder(int index)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
index int
Returns
Type Description
RecommendationOrBuilder

getRecommendationsOrBuilderList()

public List<? extends RecommendationOrBuilder> getRecommendationsOrBuilderList()

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Returns
Type Description
List<? extends com.google.cloud.recommender.v1.RecommendationOrBuilder>

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ListRecommendationsResponse other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeRecommendations(int index)

public ListRecommendationsResponse.Builder removeRecommendations(int index)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameter
Name Description
index int
Returns
Type Description
ListRecommendationsResponse.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setNextPageToken(String value)

public ListRecommendationsResponse.Builder setNextPageToken(String value)

A token that can be used to request the next page of results. This field is empty if there are no additional results.

string next_page_token = 2;

Parameter
Name Description
value String

The nextPageToken to set.

Returns
Type Description
ListRecommendationsResponse.Builder

This builder for chaining.

setNextPageTokenBytes(ByteString value)

public ListRecommendationsResponse.Builder setNextPageTokenBytes(ByteString value)

A token that can be used to request the next page of results. This field is empty if there are no additional results.

string next_page_token = 2;

Parameter
Name Description
value ByteString

The bytes for nextPageToken to set.

Returns
Type Description
ListRecommendationsResponse.Builder

This builder for chaining.

setRecommendations(int index, Recommendation value)

public ListRecommendationsResponse.Builder setRecommendations(int index, Recommendation value)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameters
Name Description
index int
value Recommendation
Returns
Type Description
ListRecommendationsResponse.Builder

setRecommendations(int index, Recommendation.Builder builderForValue)

public ListRecommendationsResponse.Builder setRecommendations(int index, Recommendation.Builder builderForValue)

The set of recommendations for the parent resource.

repeated .google.cloud.recommender.v1.Recommendation recommendations = 1;

Parameters
Name Description
index int
builderForValue Recommendation.Builder
Returns
Type Description
ListRecommendationsResponse.Builder

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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