Package com.tuladb
Record Class Models.Balance
java.lang.Object
java.lang.Record
com.tuladb.Models.Balance
- Enclosing class:
Models
public static record Models.Balance(long creditsPosted, long debitsPosted, long creditsPending, long debitsPending, long postedBalance, long availableBalance)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionBalance(long creditsPosted, long debitsPosted, long creditsPending, long debitsPending, long postedBalance, long availableBalance) Creates an instance of aBalancerecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of theavailableBalancerecord component.longReturns the value of thecreditsPendingrecord component.longReturns the value of thecreditsPostedrecord component.longReturns the value of thedebitsPendingrecord component.longReturns the value of thedebitsPostedrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.longReturns the value of thepostedBalancerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Balance
public Balance(long creditsPosted, long debitsPosted, long creditsPending, long debitsPending, long postedBalance, long availableBalance) Creates an instance of aBalancerecord class.- Parameters:
creditsPosted- the value for thecreditsPostedrecord componentdebitsPosted- the value for thedebitsPostedrecord componentcreditsPending- the value for thecreditsPendingrecord componentdebitsPending- the value for thedebitsPendingrecord componentpostedBalance- the value for thepostedBalancerecord componentavailableBalance- the value for theavailableBalancerecord 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 '=='. -
creditsPosted
public long creditsPosted()Returns the value of thecreditsPostedrecord component.- Returns:
- the value of the
creditsPostedrecord component
-
debitsPosted
public long debitsPosted()Returns the value of thedebitsPostedrecord component.- Returns:
- the value of the
debitsPostedrecord component
-
creditsPending
public long creditsPending()Returns the value of thecreditsPendingrecord component.- Returns:
- the value of the
creditsPendingrecord component
-
debitsPending
public long debitsPending()Returns the value of thedebitsPendingrecord component.- Returns:
- the value of the
debitsPendingrecord component
-
postedBalance
public long postedBalance()Returns the value of thepostedBalancerecord component.- Returns:
- the value of the
postedBalancerecord component
-
availableBalance
public long availableBalance()Returns the value of theavailableBalancerecord component.- Returns:
- the value of the
availableBalancerecord component
-