Package dev.tobee.telegram.model
Record Class SuccessfulPayment
java.lang.Object
java.lang.Record
dev.tobee.telegram.model.SuccessfulPayment
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncurrency()Returns the value of thecurrencyrecord component.booleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.Returns the value of theinvoicePayloadrecord component.Returns the value of theorderInforecord component.Returns the value of theproviderPaymentChargeIdrecord component.Returns the value of theshippingOptionIdrecord component.Returns the value of thetelegramPaymentChargeIdrecord component.toString()Returns a string representation of this record class.intReturns the value of thetotalAmountrecord component.
-
Constructor Details
-
SuccessfulPayment
public SuccessfulPayment(String currency, int totalAmount, String invoicePayload, Optional<String> shippingOptionId, Optional<OrderInfo> orderInfo, String telegramPaymentChargeId, String providerPaymentChargeId)Creates an instance of aSuccessfulPaymentrecord class.- Parameters:
currency- the value for thecurrencyrecord componenttotalAmount- the value for thetotalAmountrecord componentinvoicePayload- the value for theinvoicePayloadrecord componentshippingOptionId- the value for theshippingOptionIdrecord componentorderInfo- the value for theorderInforecord componenttelegramPaymentChargeId- the value for thetelegramPaymentChargeIdrecord componentproviderPaymentChargeId- the value for theproviderPaymentChargeIdrecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
currency
Returns the value of thecurrencyrecord component.- Returns:
- the value of the
currencyrecord component
-
totalAmount
public int totalAmount()Returns the value of thetotalAmountrecord component.- Returns:
- the value of the
totalAmountrecord component
-
invoicePayload
Returns the value of theinvoicePayloadrecord component.- Returns:
- the value of the
invoicePayloadrecord component
-
shippingOptionId
Returns the value of theshippingOptionIdrecord component.- Returns:
- the value of the
shippingOptionIdrecord component
-
orderInfo
Returns the value of theorderInforecord component.- Returns:
- the value of the
orderInforecord component
-
telegramPaymentChargeId
Returns the value of thetelegramPaymentChargeIdrecord component.- Returns:
- the value of the
telegramPaymentChargeIdrecord component
-
providerPaymentChargeId
Returns the value of theproviderPaymentChargeIdrecord component.- Returns:
- the value of the
providerPaymentChargeIdrecord component
-