Package com.github.copilot.sdk.events
Record Class SessionUsageInfoEvent.SessionUsageInfoData
java.lang.Object
java.lang.Record
com.github.copilot.sdk.events.SessionUsageInfoEvent.SessionUsageInfoData
- Enclosing class:
- SessionUsageInfoEvent
public static record SessionUsageInfoEvent.SessionUsageInfoData(double tokenLimit, double currentTokens, double messagesLength)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionSessionUsageInfoData(double tokenLimit, double currentTokens, double messagesLength) Creates an instance of aSessionUsageInfoDatarecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of thecurrentTokensrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.doubleReturns the value of themessagesLengthrecord component.doubleReturns the value of thetokenLimitrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SessionUsageInfoData
public SessionUsageInfoData(double tokenLimit, double currentTokens, double messagesLength) Creates an instance of aSessionUsageInfoDatarecord class.- Parameters:
tokenLimit- the value for thetokenLimitrecord componentcurrentTokens- the value for thecurrentTokensrecord componentmessagesLength- the value for themessagesLengthrecord 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 '=='. -
tokenLimit
public double tokenLimit()Returns the value of thetokenLimitrecord component.- Returns:
- the value of the
tokenLimitrecord component
-
currentTokens
public double currentTokens()Returns the value of thecurrentTokensrecord component.- Returns:
- the value of the
currentTokensrecord component
-
messagesLength
public double messagesLength()Returns the value of themessagesLengthrecord component.- Returns:
- the value of the
messagesLengthrecord component
-