- 3.55.0 (latest)
- 3.54.0
- 3.53.0
- 3.52.0
- 3.50.0
- 3.49.0
- 3.48.0
- 3.47.0
- 3.46.0
- 3.45.0
- 3.44.0
- 3.43.0
- 3.42.0
- 3.41.0
- 3.40.0
- 3.38.0
- 3.37.0
- 3.36.0
- 3.35.0
- 3.34.0
- 3.33.0
- 3.32.0
- 3.31.0
- 3.30.0
- 3.29.0
- 3.28.0
- 3.25.0
- 3.24.0
- 3.23.0
- 3.22.0
- 3.21.0
- 3.20.0
- 3.19.0
- 3.18.0
- 3.17.0
- 3.16.0
- 3.15.0
- 3.14.0
- 3.13.0
- 3.12.0
- 3.11.0
- 3.10.0
- 3.9.0
- 3.8.0
- 3.7.0
- 3.6.0
- 3.5.0
- 3.4.2
- 3.3.0
- 3.2.0
- 3.0.0
- 2.9.8
- 2.8.9
- 2.7.4
- 2.5.3
- 2.4.0
public static final class GenerateContentResponse.Builder extends GeneratedMessageV3.Builder<GenerateContentResponse.Builder> implements GenerateContentResponseOrBuilder
Response message for [PredictionService.GenerateContent].
Protobuf type google.cloud.aiplatform.v1beta1.GenerateContentResponse
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > GenerateContentResponse.BuilderImplements
GenerateContentResponseOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns | |
---|---|
Type | Description |
Descriptor |
Methods
addAllCandidates(Iterable<? extends Candidate> values)
public GenerateContentResponse.Builder addAllCandidates(Iterable<? extends Candidate> values)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
values |
Iterable<? extends com.google.cloud.aiplatform.v1beta1.Candidate> |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
addCandidates(Candidate value)
public GenerateContentResponse.Builder addCandidates(Candidate value)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value |
Candidate |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
addCandidates(Candidate.Builder builderForValue)
public GenerateContentResponse.Builder addCandidates(Candidate.Builder builderForValue)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
builderForValue |
Candidate.Builder |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
addCandidates(int index, Candidate value)
public GenerateContentResponse.Builder addCandidates(int index, Candidate value)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameters | |
---|---|
Name | Description |
index |
int |
value |
Candidate |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
addCandidates(int index, Candidate.Builder builderForValue)
public GenerateContentResponse.Builder addCandidates(int index, Candidate.Builder builderForValue)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameters | |
---|---|
Name | Description |
index |
int |
builderForValue |
Candidate.Builder |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
addCandidatesBuilder()
public Candidate.Builder addCandidatesBuilder()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
Candidate.Builder |
addCandidatesBuilder(int index)
public Candidate.Builder addCandidatesBuilder(int index)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
Candidate.Builder |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public GenerateContentResponse.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field |
FieldDescriptor |
value |
Object |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
build()
public GenerateContentResponse build()
Returns | |
---|---|
Type | Description |
GenerateContentResponse |
buildPartial()
public GenerateContentResponse buildPartial()
Returns | |
---|---|
Type | Description |
GenerateContentResponse |
clear()
public GenerateContentResponse.Builder clear()
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clearCandidates()
public GenerateContentResponse.Builder clearCandidates()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clearField(Descriptors.FieldDescriptor field)
public GenerateContentResponse.Builder clearField(Descriptors.FieldDescriptor field)
Parameter | |
---|---|
Name | Description |
field |
FieldDescriptor |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clearModelVersion()
public GenerateContentResponse.Builder clearModelVersion()
Output only. The model version used to generate the response.
string model_version = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public GenerateContentResponse.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter | |
---|---|
Name | Description |
oneof |
OneofDescriptor |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clearPromptFeedback()
public GenerateContentResponse.Builder clearPromptFeedback()
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clearUsageMetadata()
public GenerateContentResponse.Builder clearUsageMetadata()
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
clone()
public GenerateContentResponse.Builder clone()
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
getCandidates(int index)
public Candidate getCandidates(int index)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
Candidate |
getCandidatesBuilder(int index)
public Candidate.Builder getCandidatesBuilder(int index)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
Candidate.Builder |
getCandidatesBuilderList()
public List<Candidate.Builder> getCandidatesBuilderList()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
List<Builder> |
getCandidatesCount()
public int getCandidatesCount()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
int |
getCandidatesList()
public List<Candidate> getCandidatesList()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
List<Candidate> |
getCandidatesOrBuilder(int index)
public CandidateOrBuilder getCandidatesOrBuilder(int index)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
CandidateOrBuilder |
getCandidatesOrBuilderList()
public List<? extends CandidateOrBuilder> getCandidatesOrBuilderList()
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
List<? extends com.google.cloud.aiplatform.v1beta1.CandidateOrBuilder> |
getDefaultInstanceForType()
public GenerateContentResponse getDefaultInstanceForType()
Returns | |
---|---|
Type | Description |
GenerateContentResponse |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns | |
---|---|
Type | Description |
Descriptor |
getModelVersion()
public String getModelVersion()
Output only. The model version used to generate the response.
string model_version = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
String |
The modelVersion. |
getModelVersionBytes()
public ByteString getModelVersionBytes()
Output only. The model version used to generate the response.
string model_version = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
ByteString |
The bytes for modelVersion. |
getPromptFeedback()
public GenerateContentResponse.PromptFeedback getPromptFeedback()
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.PromptFeedback |
The promptFeedback. |
getPromptFeedbackBuilder()
public GenerateContentResponse.PromptFeedback.Builder getPromptFeedbackBuilder()
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.PromptFeedback.Builder |
getPromptFeedbackOrBuilder()
public GenerateContentResponse.PromptFeedbackOrBuilder getPromptFeedbackOrBuilder()
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
GenerateContentResponse.PromptFeedbackOrBuilder |
getUsageMetadata()
public GenerateContentResponse.UsageMetadata getUsageMetadata()
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Returns | |
---|---|
Type | Description |
GenerateContentResponse.UsageMetadata |
The usageMetadata. |
getUsageMetadataBuilder()
public GenerateContentResponse.UsageMetadata.Builder getUsageMetadataBuilder()
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Returns | |
---|---|
Type | Description |
GenerateContentResponse.UsageMetadata.Builder |
getUsageMetadataOrBuilder()
public GenerateContentResponse.UsageMetadataOrBuilder getUsageMetadataOrBuilder()
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Returns | |
---|---|
Type | Description |
GenerateContentResponse.UsageMetadataOrBuilder |
hasPromptFeedback()
public boolean hasPromptFeedback()
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
boolean |
Whether the promptFeedback field is set. |
hasUsageMetadata()
public boolean hasUsageMetadata()
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Returns | |
---|---|
Type | Description |
boolean |
Whether the usageMetadata field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns | |
---|---|
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Returns | |
---|---|
Type | Description |
boolean |
mergeFrom(GenerateContentResponse other)
public GenerateContentResponse.Builder mergeFrom(GenerateContentResponse other)
Parameter | |
---|---|
Name | Description |
other |
GenerateContentResponse |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public GenerateContentResponse.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
Exceptions | |
---|---|
Type | Description |
IOException |
mergeFrom(Message other)
public GenerateContentResponse.Builder mergeFrom(Message other)
Parameter | |
---|---|
Name | Description |
other |
Message |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
mergePromptFeedback(GenerateContentResponse.PromptFeedback value)
public GenerateContentResponse.Builder mergePromptFeedback(GenerateContentResponse.PromptFeedback value)
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value |
GenerateContentResponse.PromptFeedback |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final GenerateContentResponse.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields |
UnknownFieldSet |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
mergeUsageMetadata(GenerateContentResponse.UsageMetadata value)
public GenerateContentResponse.Builder mergeUsageMetadata(GenerateContentResponse.UsageMetadata value)
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Parameter | |
---|---|
Name | Description |
value |
GenerateContentResponse.UsageMetadata |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
removeCandidates(int index)
public GenerateContentResponse.Builder removeCandidates(int index)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
index |
int |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setCandidates(int index, Candidate value)
public GenerateContentResponse.Builder setCandidates(int index, Candidate value)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameters | |
---|---|
Name | Description |
index |
int |
value |
Candidate |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setCandidates(int index, Candidate.Builder builderForValue)
public GenerateContentResponse.Builder setCandidates(int index, Candidate.Builder builderForValue)
Output only. Generated candidates.
repeated .google.cloud.aiplatform.v1beta1.Candidate candidates = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameters | |
---|---|
Name | Description |
index |
int |
builderForValue |
Candidate.Builder |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setField(Descriptors.FieldDescriptor field, Object value)
public GenerateContentResponse.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field |
FieldDescriptor |
value |
Object |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setModelVersion(String value)
public GenerateContentResponse.Builder setModelVersion(String value)
Output only. The model version used to generate the response.
string model_version = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value |
String The modelVersion to set. |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
This builder for chaining. |
setModelVersionBytes(ByteString value)
public GenerateContentResponse.Builder setModelVersionBytes(ByteString value)
Output only. The model version used to generate the response.
string model_version = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value |
ByteString The bytes for modelVersion to set. |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
This builder for chaining. |
setPromptFeedback(GenerateContentResponse.PromptFeedback value)
public GenerateContentResponse.Builder setPromptFeedback(GenerateContentResponse.PromptFeedback value)
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value |
GenerateContentResponse.PromptFeedback |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setPromptFeedback(GenerateContentResponse.PromptFeedback.Builder builderForValue)
public GenerateContentResponse.Builder setPromptFeedback(GenerateContentResponse.PromptFeedback.Builder builderForValue)
Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.PromptFeedback prompt_feedback = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
builderForValue |
GenerateContentResponse.PromptFeedback.Builder |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public GenerateContentResponse.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters | |
---|---|
Name | Description |
field |
FieldDescriptor |
index |
int |
value |
Object |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setUnknownFields(UnknownFieldSet unknownFields)
public final GenerateContentResponse.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields |
UnknownFieldSet |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setUsageMetadata(GenerateContentResponse.UsageMetadata value)
public GenerateContentResponse.Builder setUsageMetadata(GenerateContentResponse.UsageMetadata value)
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Parameter | |
---|---|
Name | Description |
value |
GenerateContentResponse.UsageMetadata |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |
setUsageMetadata(GenerateContentResponse.UsageMetadata.Builder builderForValue)
public GenerateContentResponse.Builder setUsageMetadata(GenerateContentResponse.UsageMetadata.Builder builderForValue)
Usage metadata about the response(s).
.google.cloud.aiplatform.v1beta1.GenerateContentResponse.UsageMetadata usage_metadata = 4;
Parameter | |
---|---|
Name | Description |
builderForValue |
GenerateContentResponse.UsageMetadata.Builder |
Returns | |
---|---|
Type | Description |
GenerateContentResponse.Builder |