Package com.bank.auth_service.dto
Record Class ConfirmCodeDto
java.lang.Object
java.lang.Record
com.bank.auth_service.dto.ConfirmCodeDto
- Record Components:
key
- the unique key for the confirmationcode
- the confirmation codeidAccount
- the ID of the account associated with the paymentpixKey
- the PIX key used for the paymentpaymentId
- the ID of the payment transactionpaymentDescription
- a description of the paymentamountPaid
- the total amount paid in the transaction
public record ConfirmCodeDto(String key, String code, Long idAccount, String pixKey, Long paymentId, String paymentDescription, BigDecimal amountPaid)
extends Record
DTO representing a confirmation code for a payment transaction.
Contains the key, code, account ID, PIX key, payment ID, payment description, and the amount paid.
- Since:
- 1.0.0
- Version:
- 1.0.0, 06/23/2025
- Author:
- Fernando Cruz Cavina
-
Constructor Summary
ConstructorsConstructorDescriptionConfirmCodeDto
(String key, String code, Long idAccount, String pixKey, Long paymentId, String paymentDescription, BigDecimal amountPaid) Creates an instance of aConfirmCodeDto
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theamountPaid
record component.code()
Returns the value of thecode
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.key()
Returns the value of thekey
record component.Returns the value of thepaymentDescription
record component.Returns the value of thepaymentId
record component.pixKey()
Returns the value of thepixKey
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
ConfirmCodeDto
public ConfirmCodeDto(String key, String code, Long idAccount, String pixKey, Long paymentId, String paymentDescription, BigDecimal amountPaid) Creates an instance of aConfirmCodeDto
record class.- Parameters:
key
- the value for thekey
record componentcode
- the value for thecode
record componentidAccount
- the value for theidAccount
record componentpixKey
- the value for thepixKey
record componentpaymentId
- the value for thepaymentId
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)
. -
key
Returns the value of thekey
record component.- Returns:
- the value of the
key
record component
-
code
Returns the value of thecode
record component.- Returns:
- the value of the
code
record component
-
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
-
paymentId
Returns the value of thepaymentId
record component.- Returns:
- the value of the
paymentId
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
-