Record Class GenerateContentResponse.UsageMetadata
java.lang.Object
java.lang.Record
io.quarkiverse.langchain4j.vertexai.runtime.gemini.GenerateContentResponse.UsageMetadata
- Enclosing class:
- GenerateContentResponse
-
Constructor Summary
ConstructorsConstructorDescriptionUsageMetadata(Integer promptTokenCount, Integer candidatesTokenCount, Integer totalTokenCount) Creates an instance of aUsageMetadatarecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecandidatesTokenCountrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thepromptTokenCountrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetotalTokenCountrecord component.
-
Constructor Details
-
UsageMetadata
public UsageMetadata(Integer promptTokenCount, Integer candidatesTokenCount, Integer totalTokenCount) Creates an instance of aUsageMetadatarecord class.- Parameters:
promptTokenCount- the value for thepromptTokenCountrecord componentcandidatesTokenCount- the value for thecandidatesTokenCountrecord componenttotalTokenCount- the value for thetotalTokenCountrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
promptTokenCount
Returns the value of thepromptTokenCountrecord component.- Returns:
- the value of the
promptTokenCountrecord component
-
candidatesTokenCount
Returns the value of thecandidatesTokenCountrecord component.- Returns:
- the value of the
candidatesTokenCountrecord component
-
totalTokenCount
Returns the value of thetotalTokenCountrecord component.- Returns:
- the value of the
totalTokenCountrecord component
-