Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
package com.riskified;

public enum _type {
public enum PaymentType {
credit_card, paypal
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.util.Date;

import com.riskified.PaymentType;
import com.riskified.validations.*;

public class CreditCardPaymentDetails implements IPaymentDetails {
Expand All @@ -16,7 +17,7 @@ public class CreditCardPaymentDetails implements IPaymentDetails {
private AuthorizationError authorizationError;
private AuthenticationResult authenticationResult;
private String cardholderName;
private com.riskified._type _type;
private PaymentType payment_type;
private String id;
private String gateway;
private String acquirerBin;
Expand All @@ -39,6 +40,7 @@ public CreditCardPaymentDetails(String creditCardBin,
this.cvvResultCode = cvvResultCode;
this.creditCardNumber = creditCardNumber;
this.creditCardCompany = creditCardCompany;
this.payment_type = PaymentType.credit_card;

}

Expand Down Expand Up @@ -157,12 +159,12 @@ public void setCardholderName(String cardholderName) {
this.cardholderName = cardholderName;
}

public com.riskified._type getType() {
return _type;
public PaymentType getType() {
return payment_type;
}

public void setType(com.riskified._type type) {
this._type = type;
public void setType(PaymentType type) {
this.payment_type = type;
}

public String getId() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.riskified.models;

import com.riskified.PaymentType;
import com.riskified.validations.*;

public class PaypalPaymentDetails implements IPaymentDetails {
Expand All @@ -13,7 +14,7 @@ public class PaypalPaymentDetails implements IPaymentDetails {
private String authorizationId;
private AuthorizationError authorizationError;
private AuthenticationResult authenticationResult;
private com.riskified._type _type;
private PaymentType payment_type;
private String id;
private String gateway;
private String acquirerBin;
Expand All @@ -27,6 +28,7 @@ public PaypalPaymentDetails(String payerEmail, String payerStatus, String payerA
this.payerStatus = payerStatus;
this.payerAddressStatus = payerAddressStatus;
this.protectionEligibility = protectionEligibility;
this.payment_type = PaymentType.paypal;
}

public void validate(Validation validationType)
Expand Down Expand Up @@ -112,12 +114,12 @@ public void setAuthorizationError(AuthorizationError authorizationError) {
this.authorizationError = authorizationError;
}

public com.riskified._type getType() {
return _type;
public PaymentType getType() {
return payment_type;
}

public void setType(com.riskified._type type) {
this._type = type;
public void setType(PaymentType type) {
this.payment_type = type;
}

public String getId() {
Expand Down