Skip to content

[checkout] Code generation: update services and models#2015

Open
AdyenAutomationBot wants to merge 1 commit into
mainfrom
sdk-automation/checkout
Open

[checkout] Code generation: update services and models#2015
AdyenAutomationBot wants to merge 1 commit into
mainfrom
sdk-automation/checkout

Conversation

@AdyenAutomationBot

Copy link
Copy Markdown
Collaborator

This PR contains the automated changes for the checkout service.

The commit history of this PR reflects the adyen-openapi commits that have been applied.

@AdyenAutomationBot
AdyenAutomationBot requested a review from a team as a code owner July 23, 2026 11:56

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the SepaDirectDebitDonations model class and integrates it into DonationPaymentMethod. It also shifts the gopay_wallet payment method mapping from PaymentDetails to StoredPaymentMethodDetails. Feedback is provided on the newly added SepaDirectDebitDonations class to optimize its equals method by using primitive equality operators (==) for boolean fields instead of Objects.equals(), which avoids unnecessary auto-boxing.

Comment on lines +337 to +352
return Objects.equals(this.checkoutAttemptId, sepaDirectDebitDonations.checkoutAttemptId)
&& Objects.equals(
this.isSetCheckoutAttemptId, sepaDirectDebitDonations.isSetCheckoutAttemptId)
&& Objects.equals(
this.recurringDetailReference, sepaDirectDebitDonations.recurringDetailReference)
&& Objects.equals(
this.isSetRecurringDetailReference,
sepaDirectDebitDonations.isSetRecurringDetailReference)
&& Objects.equals(this.sdkData, sepaDirectDebitDonations.sdkData)
&& Objects.equals(this.isSetSdkData, sepaDirectDebitDonations.isSetSdkData)
&& Objects.equals(
this.storedPaymentMethodId, sepaDirectDebitDonations.storedPaymentMethodId)
&& Objects.equals(
this.isSetStoredPaymentMethodId, sepaDirectDebitDonations.isSetStoredPaymentMethodId)
&& Objects.equals(this.type, sepaDirectDebitDonations.type)
&& Objects.equals(this.isSetType, sepaDirectDebitDonations.isSetType);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Comparing primitive boolean fields using Objects.equals() causes unnecessary auto-boxing of both operands into Boolean objects. This introduces garbage collection overhead and is inefficient, especially for frequently called methods like equals(). Use the primitive equality operator == instead.

    return Objects.equals(this.checkoutAttemptId, sepaDirectDebitDonations.checkoutAttemptId)
        && this.isSetCheckoutAttemptId == sepaDirectDebitDonations.isSetCheckoutAttemptId
        && Objects.equals(
            this.recurringDetailReference, sepaDirectDebitDonations.recurringDetailReference)
        && this.isSetRecurringDetailReference == sepaDirectDebitDonations.isSetRecurringDetailReference
        && Objects.equals(this.sdkData, sepaDirectDebitDonations.sdkData)
        && this.isSetSdkData == sepaDirectDebitDonations.isSetSdkData
        && Objects.equals(
            this.storedPaymentMethodId, sepaDirectDebitDonations.storedPaymentMethodId)
        && this.isSetStoredPaymentMethodId == sepaDirectDebitDonations.isSetStoredPaymentMethodId
        && Objects.equals(this.type, sepaDirectDebitDonations.type)
        && this.isSetType == sepaDirectDebitDonations.isSetType;

mappings.put("giftcard", CardDetails.class);
mappings.put("googlepay", GooglePayDetails.class);
mappings.put("gopay_wallet", PaymentDetails.class);
mappings.put("gopay_wallet", StoredPaymentMethodDetails.class);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Breaking change

@poojah-adyen
poojah-adyen enabled auto-merge July 23, 2026 13:08
@AdyenAutomationBot
AdyenAutomationBot force-pushed the sdk-automation/checkout branch from 7b3251f to 60bfbc0 Compare July 23, 2026 13:26
@sonarqubecloud

Copy link
Copy Markdown

@poojah-adyen poojah-adyen added the Breaking change Indicates a change that has caused a major version update label Jul 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Breaking change Indicates a change that has caused a major version update

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants