3434import com .google .gson .annotations .JsonAdapter ;
3535import com .google .gson .annotations .SerializedName ;
3636
37+
3738/**
3839 * AbstractPaymentRequest Base for PaymentRequest and PaymentRequest3D
3940 */
@@ -96,6 +97,33 @@ public String toString() {
9697 @ SerializedName ("fraudOffset" )
9798 private Integer fraudOffset = null ;
9899
100+ /**
101+ * How to process a combo card (for some Brazilian cards only). Allowed values: * debit * credit
102+ */
103+ public enum FundingSourceEnum {
104+
105+ @ SerializedName ("debit" ) DEBIT ("debit" ),
106+ @ SerializedName ("credit" ) CREDIT ("credit" );
107+
108+ private String value ;
109+
110+ FundingSourceEnum (String value ) {
111+ this .value = value ;
112+ }
113+
114+ public String getValue () {
115+ return value ;
116+ }
117+
118+ @ Override
119+ public String toString () {
120+ return String .valueOf (value );
121+ }
122+ }
123+
124+ @ SerializedName ("fundingSource" )
125+ private FundingSourceEnum fundingSource = null ;
126+
99127 @ SerializedName ("sessionId" )
100128 private String sessionId = null ;
101129
@@ -173,7 +201,8 @@ public AbstractPaymentRequest() {
173201
174202 /**
175203 * Set browser data
176- * @param userAgent http header
204+ *
205+ * @param userAgent http header
177206 * @param acceptHeader http header
178207 * @return browser data
179208 */
@@ -415,6 +444,25 @@ public T sessionId(String sessionId) {
415444 return (T ) this ;
416445 }
417446
447+ public T fundingSource (FundingSourceEnum fundingSource ) {
448+ this .fundingSource = fundingSource ;
449+ return (T ) this ;
450+ }
451+
452+ /**
453+ * How to process a combo card (for some Brazilian cards only). Allowed values: * debit * credit
454+ *
455+ * @return fundingSource
456+ **/
457+ public FundingSourceEnum getFundingSource () {
458+ return fundingSource ;
459+ }
460+
461+ public void setFundingSource (FundingSourceEnum fundingSource ) {
462+ this .fundingSource = fundingSource ;
463+ }
464+
465+
418466 /**
419467 * Get sessionId
420468 *
@@ -781,6 +829,7 @@ public T enableRealTimeUpdate(Boolean enableRealTimeUpdate) {
781829
782830 /**
783831 * Choose if a specific transaction should use the Real-time Account Updater, regardless of other settings.
832+ *
784833 * @return enableRealTimeUpdate
785834 **/
786835 public Boolean isEnableRealTimeUpdate () {
@@ -798,6 +847,7 @@ public T threeDSAuthenticationOnly(Boolean threeDSAuthenticationOnly) {
798847
799848 /**
800849 * If set to true, you will only perform the [3D Secure 2 authentication](https://docs.adyen.com/checkout/3d-secure/native-3ds2/authentication-only), and not the payment authorisation.
850+ *
801851 * @return threeDSAuthenticationOnly
802852 **/
803853 public Boolean isThreeDSAuthenticationOnly () {
@@ -829,6 +879,7 @@ public boolean equals(Object o) {
829879 && Objects .equals (this .recurring , paymentRequest .recurring )
830880 && Objects .equals (this .shopperStatement , paymentRequest .shopperStatement )
831881 && Objects .equals (this .fraudOffset , paymentRequest .fraudOffset )
882+ && Objects .equals (this .fundingSource , paymentRequest .fundingSource )
832883 && Objects .equals (this .sessionId , paymentRequest .sessionId )
833884 && Objects .equals (this .additionalAmount , paymentRequest .additionalAmount )
834885 && Objects .equals (this .selectedRecurringDetailReference , paymentRequest .selectedRecurringDetailReference )
@@ -857,40 +908,41 @@ public boolean equals(Object o) {
857908 @ Override
858909 public int hashCode () {
859910 return Objects .hash (amount ,
860- reference ,
861- billingAddress ,
862- shopperIP ,
863- merchantAccount ,
864- browserInfo ,
865- shopperInteraction ,
866- shopperEmail ,
867- shopperReference ,
868- recurring ,
869- shopperStatement ,
870- fraudOffset ,
871- sessionId ,
872- additionalAmount ,
873- selectedRecurringDetailReference ,
874- orderReference ,
875- merchantOrderReference ,
876- dccQuote ,
877- additionalData ,
878- shopperName ,
879- shopperLocale ,
880- selectedBrand ,
881- deliveryAddress ,
882- deliveryDate ,
883- deviceFingerprint ,
884- installments ,
885- socialSecurityNumber ,
886- captureDelayHours ,
887- dateOfBirth ,
888- telephoneNumber ,
889- mcc ,
890- metadata ,
891- applicationInfo ,
892- enableRealTimeUpdate ,
893- threeDSAuthenticationOnly );
911+ reference ,
912+ billingAddress ,
913+ shopperIP ,
914+ merchantAccount ,
915+ browserInfo ,
916+ shopperInteraction ,
917+ shopperEmail ,
918+ shopperReference ,
919+ recurring ,
920+ shopperStatement ,
921+ fraudOffset ,
922+ fundingSource ,
923+ sessionId ,
924+ additionalAmount ,
925+ selectedRecurringDetailReference ,
926+ orderReference ,
927+ merchantOrderReference ,
928+ dccQuote ,
929+ additionalData ,
930+ shopperName ,
931+ shopperLocale ,
932+ selectedBrand ,
933+ deliveryAddress ,
934+ deliveryDate ,
935+ deviceFingerprint ,
936+ installments ,
937+ socialSecurityNumber ,
938+ captureDelayHours ,
939+ dateOfBirth ,
940+ telephoneNumber ,
941+ mcc ,
942+ metadata ,
943+ applicationInfo ,
944+ enableRealTimeUpdate ,
945+ threeDSAuthenticationOnly );
894946 }
895947
896948 @ Override
@@ -909,6 +961,7 @@ public String toString() {
909961 sb .append (" recurring: " ).append (toIndentedString (recurring )).append ("\n " );
910962 sb .append (" shopperStatement: " ).append (toIndentedString (shopperStatement )).append ("\n " );
911963 sb .append (" fraudOffset: " ).append (toIndentedString (fraudOffset )).append ("\n " );
964+ sb .append (" fundingSource: " ).append (toIndentedString (fundingSource )).append ("\n " );
912965 sb .append (" sessionId: " ).append (toIndentedString (sessionId )).append ("\n " );
913966 sb .append (" additionalAmount: " ).append (toIndentedString (additionalAmount )).append ("\n " );
914967 sb .append (" selectedRecurringDetailReference: " ).append (toIndentedString (selectedRecurringDetailReference )).append ("\n " );
@@ -943,10 +996,10 @@ private String stringifyAdditionalData() {
943996
944997 Map <String , String > nonSensitiveAdditionalData = new HashMap <String , String >(additionalData );
945998 List <String > keys = Arrays .asList (ApiConstants .AdditionalData .Card .Encrypted .JSON ,
946- ApiConstants .AdditionalData .ENCRYPTED_CARD_NUMBER ,
947- ApiConstants .AdditionalData .ENCRYPTED_EXPIRY_MONTH ,
948- ApiConstants .AdditionalData .ENCRYPTED_EXPIRY_YEAR ,
949- ApiConstants .AdditionalData .ENCRYPTED_SECURITY_CODE );
999+ ApiConstants .AdditionalData .ENCRYPTED_CARD_NUMBER ,
1000+ ApiConstants .AdditionalData .ENCRYPTED_EXPIRY_MONTH ,
1001+ ApiConstants .AdditionalData .ENCRYPTED_EXPIRY_YEAR ,
1002+ ApiConstants .AdditionalData .ENCRYPTED_SECURITY_CODE );
9501003
9511004 for (String key : keys ) {
9521005 if (nonSensitiveAdditionalData .containsKey (key )) {
0 commit comments