publicstaticfinalclass GenerateContentResponse.UsageMetadataextendsGeneratedMessageV3implementsGenerateContentResponse.UsageMetadataOrBuilder
Usage metadata about response(s).
Protobuf type google.cloud.vertexai.v1.GenerateContentResponse.UsageMetadata
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
CACHED_CONTENT_TOKEN_COUNT_FIELD_NUMBER
publicstaticfinalintCACHED_CONTENT_TOKEN_COUNT_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
CACHE_TOKENS_DETAILS_FIELD_NUMBER
publicstaticfinalintCACHE_TOKENS_DETAILS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
CANDIDATES_TOKENS_DETAILS_FIELD_NUMBER
publicstaticfinalintCANDIDATES_TOKENS_DETAILS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
CANDIDATES_TOKEN_COUNT_FIELD_NUMBER
publicstaticfinalintCANDIDATES_TOKEN_COUNT_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
PROMPT_TOKENS_DETAILS_FIELD_NUMBER
publicstaticfinalintPROMPT_TOKENS_DETAILS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
PROMPT_TOKEN_COUNT_FIELD_NUMBER
publicstaticfinalintPROMPT_TOKEN_COUNT_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
TOTAL_TOKEN_COUNT_FIELD_NUMBER
publicstaticfinalintTOTAL_TOKEN_COUNT_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
Static Methods
getDefaultInstance()
publicstaticGenerateContentResponse.UsageMetadatagetDefaultInstance()
getDescriptor()
publicstaticfinalDescriptors.DescriptorgetDescriptor()
newBuilder()
publicstaticGenerateContentResponse.UsageMetadata.BuildernewBuilder()
newBuilder(GenerateContentResponse.UsageMetadata prototype)
publicstaticGenerateContentResponse.UsageMetadata.BuildernewBuilder(GenerateContentResponse.UsageMetadataprototype)
parseDelimitedFrom(InputStream input)
publicstaticGenerateContentResponse.UsageMetadataparseDelimitedFrom(InputStreaminput)
parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseDelimitedFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
parseFrom(byte[] data)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(byte[]data)
| Parameter |
| Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(byte[]data,ExtensionRegistryLiteextensionRegistry)
parseFrom(ByteString data)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(ByteStringdata)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(ByteStringdata,ExtensionRegistryLiteextensionRegistry)
parseFrom(CodedInputStream input)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(CodedInputStreaminput)
parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
parseFrom(InputStream input)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(InputStreaminput)
parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
parseFrom(ByteBuffer data)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(ByteBufferdata)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
publicstaticGenerateContentResponse.UsageMetadataparseFrom(ByteBufferdata,ExtensionRegistryLiteextensionRegistry)
parser()
publicstaticParser<GenerateContentResponse.UsageMetadata>parser()
Methods
equals(Object obj)
publicbooleanequals(Objectobj)
| Parameter |
| Name |
Description |
obj |
Object
|
Overrides
getCacheTokensDetails(int index)
publicModalityTokenCountgetCacheTokensDetails(intindex)
Output only. List of modalities of the cached content in the request
input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount cache_tokens_details = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getCacheTokensDetailsCount()
publicintgetCacheTokensDetailsCount()
Output only. List of modalities of the cached content in the request
input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount cache_tokens_details = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
int |
getCacheTokensDetailsList()
publicList<ModalityTokenCount>getCacheTokensDetailsList()
Output only. List of modalities of the cached content in the request
input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount cache_tokens_details = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCacheTokensDetailsOrBuilder(int index)
publicModalityTokenCountOrBuildergetCacheTokensDetailsOrBuilder(intindex)
Output only. List of modalities of the cached content in the request
input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount cache_tokens_details = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getCacheTokensDetailsOrBuilderList()
publicList<?extendsModalityTokenCountOrBuilder>getCacheTokensDetailsOrBuilderList()
Output only. List of modalities of the cached content in the request
input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount cache_tokens_details = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
List<? extends com.google.cloud.vertexai.api.ModalityTokenCountOrBuilder> |
getCachedContentTokenCount()
publicintgetCachedContentTokenCount()
Output only. Number of tokens in the cached part in the input (the cached
content).
int32 cached_content_token_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
int |
The cachedContentTokenCount.
|
getCandidatesTokenCount()
publicintgetCandidatesTokenCount()
Number of tokens in the response(s).
int32 candidates_token_count = 2;
| Returns |
| Type |
Description |
int |
The candidatesTokenCount.
|
getCandidatesTokensDetails(int index)
publicModalityTokenCountgetCandidatesTokensDetails(intindex)
Output only. List of modalities that were returned in the response.
repeated .google.cloud.vertexai.v1.ModalityTokenCount candidates_tokens_details = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getCandidatesTokensDetailsCount()
publicintgetCandidatesTokensDetailsCount()
Output only. List of modalities that were returned in the response.
repeated .google.cloud.vertexai.v1.ModalityTokenCount candidates_tokens_details = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
int |
getCandidatesTokensDetailsList()
publicList<ModalityTokenCount>getCandidatesTokensDetailsList()
Output only. List of modalities that were returned in the response.
repeated .google.cloud.vertexai.v1.ModalityTokenCount candidates_tokens_details = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCandidatesTokensDetailsOrBuilder(int index)
publicModalityTokenCountOrBuildergetCandidatesTokensDetailsOrBuilder(intindex)
Output only. List of modalities that were returned in the response.
repeated .google.cloud.vertexai.v1.ModalityTokenCount candidates_tokens_details = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getCandidatesTokensDetailsOrBuilderList()
publicList<?extendsModalityTokenCountOrBuilder>getCandidatesTokensDetailsOrBuilderList()
Output only. List of modalities that were returned in the response.
repeated .google.cloud.vertexai.v1.ModalityTokenCount candidates_tokens_details = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
List<? extends com.google.cloud.vertexai.api.ModalityTokenCountOrBuilder> |
getDefaultInstanceForType()
publicGenerateContentResponse.UsageMetadatagetDefaultInstanceForType()
getParserForType()
publicParser<GenerateContentResponse.UsageMetadata>getParserForType()
Overrides
getPromptTokenCount()
publicintgetPromptTokenCount()
Number of tokens in the request. When cached_content is set, this is
still the total effective prompt size meaning this includes the number of
tokens in the cached content.
int32 prompt_token_count = 1;
| Returns |
| Type |
Description |
int |
The promptTokenCount.
|
getPromptTokensDetails(int index)
publicModalityTokenCountgetPromptTokensDetails(intindex)
Output only. List of modalities that were processed in the request input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount prompt_tokens_details = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getPromptTokensDetailsCount()
publicintgetPromptTokensDetailsCount()
Output only. List of modalities that were processed in the request input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount prompt_tokens_details = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
int |
getPromptTokensDetailsList()
publicList<ModalityTokenCount>getPromptTokensDetailsList()
Output only. List of modalities that were processed in the request input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount prompt_tokens_details = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
getPromptTokensDetailsOrBuilder(int index)
publicModalityTokenCountOrBuildergetPromptTokensDetailsOrBuilder(intindex)
Output only. List of modalities that were processed in the request input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount prompt_tokens_details = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter |
| Name |
Description |
index |
int
|
getPromptTokensDetailsOrBuilderList()
publicList<?extendsModalityTokenCountOrBuilder>getPromptTokensDetailsOrBuilderList()
Output only. List of modalities that were processed in the request input.
repeated .google.cloud.vertexai.v1.ModalityTokenCount prompt_tokens_details = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns |
| Type |
Description |
List<? extends com.google.cloud.vertexai.api.ModalityTokenCountOrBuilder> |
getSerializedSize()
publicintgetSerializedSize()
| Returns |
| Type |
Description |
int |
Overrides
getTotalTokenCount()
publicintgetTotalTokenCount()
Total token count for prompt and response candidates.
int32 total_token_count = 3;
| Returns |
| Type |
Description |
int |
The totalTokenCount.
|
hashCode()
| Returns |
| Type |
Description |
int |
Overrides
internalGetFieldAccessorTable()
protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Overrides
isInitialized()
publicfinalbooleanisInitialized()
Overrides
newBuilderForType()
publicGenerateContentResponse.UsageMetadata.BuildernewBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protectedGenerateContentResponse.UsageMetadata.BuildernewBuilderForType(GeneratedMessageV3.BuilderParentparent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protectedObjectnewInstance(GeneratedMessageV3.UnusedPrivateParameterunused)
| Returns |
| Type |
Description |
Object |
Overrides
toBuilder()
publicGenerateContentResponse.UsageMetadata.BuildertoBuilder()
writeTo(CodedOutputStream output)
publicvoidwriteTo(CodedOutputStreamoutput)
Overrides