Package com.bank.payment.dtos
Record Class ConclusionPaymentDto
java.lang.Object
java.lang.Record
com.bank.payment.dtos.ConclusionPaymentDto
- Record Components:
idAccount
- the ID of the account making the paymentpixKey
- the Pix key associated with the paymentpaymentDescription
- a description of the paymentamountPaid
- the amount that has been paid
public record ConclusionPaymentDto(Long idAccount, String pixKey, String paymentDescription, BigDecimal amountPaid)
extends Record
DTO for concluding a payment.
This DTO contains the necessary information to finalize a payment transaction.
- Since:
- 1.0.0
- Version:
- 1.0.0, 06/26/2025
- Author:
- Fernando Cruz Cavina
-
Constructor Summary
ConstructorsConstructorDescriptionConclusionPaymentDto
(Long idAccount, String pixKey, String paymentDescription, BigDecimal amountPaid) Creates an instance of aConclusionPaymentDto
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theamountPaid
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of theidAccount
record component.Returns the value of thepaymentDescription
record component.pixKey()
Returns the value of thepixKey
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
ConclusionPaymentDto
public ConclusionPaymentDto(Long idAccount, String pixKey, String paymentDescription, BigDecimal amountPaid) Creates an instance of aConclusionPaymentDto
record class.- Parameters:
idAccount
- the value for theidAccount
record componentpixKey
- the value for thepixKey
record componentpaymentDescription
- the value for thepaymentDescription
record componentamountPaid
- the value for theamountPaid
record 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)
. -
idAccount
Returns the value of theidAccount
record component.- Returns:
- the value of the
idAccount
record component
-
pixKey
Returns the value of thepixKey
record component.- Returns:
- the value of the
pixKey
record component
-
paymentDescription
Returns the value of thepaymentDescription
record component.- Returns:
- the value of the
paymentDescription
record component
-
amountPaid
Returns the value of theamountPaid
record component.- Returns:
- the value of the
amountPaid
record component
-