Record Class Batch.RequestCounts
java.lang.Object
java.lang.Record
io.github.stefanbratanov.jvm.openai.Batch.RequestCounts
- Enclosing class:
- Batch
-
Constructor Summary
ConstructorsConstructorDescriptionRequestCounts(int total, int completed, int failed) Creates an instance of aRequestCountsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of thecompletedrecord component.final booleanIndicates whether some other object is "equal to" this one.intfailed()Returns the value of thefailedrecord component.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.inttotal()Returns the value of thetotalrecord component.
-
Constructor Details
-
RequestCounts
public RequestCounts(int total, int completed, int failed) Creates an instance of aRequestCountsrecord class.- Parameters:
total- the value for thetotalrecord componentcompleted- the value for thecompletedrecord componentfailed- the value for thefailedrecord 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 with '=='. -
total
public int total()Returns the value of thetotalrecord component.- Returns:
- the value of the
totalrecord component
-
completed
public int completed()Returns the value of thecompletedrecord component.- Returns:
- the value of the
completedrecord component
-
failed
public int failed()Returns the value of thefailedrecord component.- Returns:
- the value of the
failedrecord component
-