Record Class AccountLedgerPendingStateDTO
java.lang.Object
java.lang.Record
com.bluebell.greenhouse.platform.models.api.dto.account.AccountLedgerPendingStateDTO
- Record Components:
positionNumber- position numberpositionName- position nameopenQuantity- quantity remaining openclosedQuantity- quantity closed before final closurependingRealizedAmount- cumulative pending realized resultpartialClosureCount- contributing closing order countlastPartialClosureAt- most recent contributing close timestamp
public record AccountLedgerPendingStateDTO(long positionNumber, String positionName, double openQuantity, double closedQuantity, double pendingRealizedAmount, int partialClosureCount, LocalDateTime lastPartialClosureAt)
extends Record
Immutable replay state for one position's pending partial-close activity.
- Version:
- 3.0.1
- Author:
- Stephen Prizio
-
Constructor Summary
ConstructorsConstructorDescriptionAccountLedgerPendingStateDTO(long positionNumber, String positionName, double openQuantity, double closedQuantity, double pendingRealizedAmount, int partialClosureCount, LocalDateTime lastPartialClosureAt) Creates an instance of aAccountLedgerPendingStateDTOrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of theclosedQuantityrecord 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 thelastPartialClosureAtrecord component.doubleReturns the value of theopenQuantityrecord component.intReturns the value of thepartialClosureCountrecord component.doubleReturns the value of thependingRealizedAmountrecord component.Returns the value of thepositionNamerecord component.longReturns the value of thepositionNumberrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
AccountLedgerPendingStateDTO
public AccountLedgerPendingStateDTO(long positionNumber, String positionName, double openQuantity, double closedQuantity, double pendingRealizedAmount, int partialClosureCount, LocalDateTime lastPartialClosureAt) Creates an instance of aAccountLedgerPendingStateDTOrecord class.- Parameters:
positionNumber- the value for thepositionNumberrecord componentpositionName- the value for thepositionNamerecord componentopenQuantity- the value for theopenQuantityrecord componentclosedQuantity- the value for theclosedQuantityrecord componentpendingRealizedAmount- the value for thependingRealizedAmountrecord componentpartialClosureCount- the value for thepartialClosureCountrecord componentlastPartialClosureAt- the value for thelastPartialClosureAtrecord component
-
-
Method Details
-
toString
-
hashCode
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
positionNumber
public long positionNumber()Returns the value of thepositionNumberrecord component.- Returns:
- the value of the
positionNumberrecord component
-
positionName
Returns the value of thepositionNamerecord component.- Returns:
- the value of the
positionNamerecord component
-
openQuantity
public double openQuantity()Returns the value of theopenQuantityrecord component.- Returns:
- the value of the
openQuantityrecord component
-
closedQuantity
public double closedQuantity()Returns the value of theclosedQuantityrecord component.- Returns:
- the value of the
closedQuantityrecord component
-
pendingRealizedAmount
public double pendingRealizedAmount()Returns the value of thependingRealizedAmountrecord component.- Returns:
- the value of the
pendingRealizedAmountrecord component
-
partialClosureCount
public int partialClosureCount()Returns the value of thepartialClosureCountrecord component.- Returns:
- the value of the
partialClosureCountrecord component
-
lastPartialClosureAt
Returns the value of thelastPartialClosureAtrecord component.- Returns:
- the value of the
lastPartialClosureAtrecord component
-