-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #59 from Adyen/release/3.3.0
Release 3.3.0
- Loading branch information
Showing
13 changed files
with
106 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
@NamespaceAccessible | ||
public with sharing class CancelRequest { | ||
@NamespaceAccessible | ||
public ApplicationInfo applicationInfo { get; set; } | ||
|
||
@NamespaceAccessible | ||
public String merchantAccount { get; set; } | ||
|
||
@NamespaceAccessible | ||
public String reference { get; set; } | ||
|
||
@NamespaceAccessible | ||
public Boolean equals(Object obj) { | ||
if (obj instanceof CancelRequest) { | ||
CancelRequest thatCancelRequest = (CancelRequest) obj; | ||
return this.applicationInfo == thatCancelRequest.applicationInfo | ||
&& this.merchantAccount.equals(thatCancelRequest.merchantAccount) | ||
&& this.reference.equals(thatCancelRequest.reference); | ||
} | ||
return false; | ||
} | ||
|
||
@NamespaceAccessible | ||
public Integer hashCode() { | ||
Integer hashCode = 43; | ||
hashCode = (17 * hashCode) + (applicationInfo == null ? 0 : System.hashCode(applicationInfo)); | ||
hashCode = (17 * hashCode) + (merchantAccount == null ? 0 : System.hashCode(merchantAccount)); | ||
hashCode = (17 * hashCode) + (reference == null ? 0 : System.hashCode(reference)); | ||
return hashCode; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
@IsTest | ||
private class CancelRequestTest { | ||
@IsTest | ||
static void cancelRequestTest() { | ||
// given | ||
CancelRequest cancelRequest = new CancelRequest(); | ||
cancelRequest.merchantAccount = 'test'; | ||
cancelRequest.reference = 'abc123'; | ||
CancelRequest cancelRequest2 = new CancelRequest(); | ||
cancelRequest2.merchantAccount = 'test 2'; | ||
cancelRequest2.reference = 'fgh456'; | ||
// then | ||
Assert.areEqual(cancelRequest, cancelRequest); | ||
Assert.areEqual(cancelRequest2, cancelRequest2); | ||
Assert.areNotEqual(cancelRequest, cancelRequest2); | ||
Assert.areNotEqual(cancelRequest.hashCode(), cancelRequest2.hashCode()); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
force-app/main/default/classes/CancelRequestTest.cls-meta.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,65 +1,33 @@ | ||
/* | ||
* Represents the capture response object of the Adyen API | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public with sharing class CancelResponse { | ||
|
||
/** | ||
* Get errorCode | ||
* @return errorCode | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String errorCode { get; set; } | ||
|
||
/** | ||
* Get errorType | ||
* @return errorType | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String errorType { get; set; } | ||
|
||
/** | ||
* Get message | ||
* @return message | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String message { get; set; } | ||
|
||
/** | ||
* Get merchantAccount | ||
* @return merchantAccount | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String merchantAccount { get; set; } | ||
|
||
/** | ||
* Get paymentPspReference | ||
* @return paymentPspReference | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String paymentPspReference { get; set; } | ||
|
||
/** | ||
* Get pspReference | ||
* @return pspReference | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String pspReference { get; set; } | ||
|
||
/** | ||
* Get reference | ||
* @return reference | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String reference { get; set; } | ||
|
||
/** | ||
* Get status | ||
* @return status | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String status { get; set; } | ||
|
||
@namespaceAccessible | ||
public CancelResponse(){} | ||
@NamespaceAccessible | ||
public CancelResponse() {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>52.0</apiVersion> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,118 +1,95 @@ | ||
/* | ||
* Represents an Adyen Capture Request | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public with sharing class CaptureRequest implements ModificationRequest { | ||
|
||
/** | ||
* additional data | ||
* @return additionalData | ||
*/ | ||
@namespaceAccessible | ||
|
||
@NamespaceAccessible | ||
public String additionalData { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String getAdditionalData() { | ||
return additionalData; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setAdditionalData(String additionalData) { | ||
this.additionalData = additionalData; | ||
} | ||
|
||
/** | ||
* application info | ||
* @return applicationInfo | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public ApplicationInfo applicationInfo { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public ApplicationInfo getApplicationInfo() { | ||
return applicationInfo; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setApplicationInfo(ApplicationInfo applicationInfo) { | ||
this.applicationInfo = applicationInfo; | ||
} | ||
|
||
/** | ||
* original payment reference | ||
* @return originalReference | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String originalReference { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String getOriginalReference() { | ||
return originalReference; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setOriginalReference(String originalReference) { | ||
this.originalReference = originalReference; | ||
} | ||
|
||
/** | ||
* Payment capture amount | ||
* @return amount | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public Amount modificationAmount { get; set; } | ||
|
||
/** | ||
* Payment capture amount | ||
* @return amount | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public Amount amount { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public Amount getAmount() { | ||
return amount; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setAmount(Amount amount) { | ||
this.amount = amount; | ||
} | ||
|
||
/** | ||
* The reference to uniquely identify a payment. This reference is used in all communication with you about the payment status. We recommend using a unique value per payment; however, it is not a requirement.\nIf you need to provide multiple references for a transaction, separate them with hyphens ("-").\nMaximum length: 80 characters. | ||
* @return reference | ||
* The reference to uniquely identify a payment. This reference is used in all communication with you about the payment status. | ||
* We recommend using a unique value per payment; however, it is not a requirement. | ||
* If you need to provide multiple references for a transaction, separate them with hyphens ("-"). Maximum length: 80 characters. | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String reference { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String getReference() { | ||
return reference; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setReference(String reference) { | ||
this.reference = reference; | ||
} | ||
|
||
/** | ||
* Merchant account name | ||
* @return merchantAccount | ||
*/ | ||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String merchantAccount { get; set; } | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public String getMerchantAccount() { | ||
return merchantAccount; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public void setMerchantAccount(String merchantAccount) { | ||
this.merchantAccount = merchantAccount; | ||
} | ||
|
||
@namespaceAccessible | ||
@NamespaceAccessible | ||
public CaptureRequest(){} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>52.0</apiVersion> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
2 changes: 1 addition & 1 deletion
2
force-app/main/default/classes/CheckoutCaptureRequest.cls-meta.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>52.0</apiVersion> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>60.0</apiVersion> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
force-app/main/default/classes/ModificationRequest.cls-meta.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>52.0</apiVersion> | ||
<apiVersion>61.0</apiVersion> | ||
<status>Active</status> | ||
</ApexClass> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,15 +4,15 @@ | |
"path": "force-app", | ||
"default": true, | ||
"package": "API Library Apex Adyen", | ||
"versionName": "version 3.2", | ||
"versionNumber": "3.2.0.NEXT", | ||
"versionName": "version 3.3", | ||
"versionNumber": "3.3.0.NEXT", | ||
"ancestorVersion": "HIGHEST" | ||
} | ||
], | ||
"name": "adyen-apex-api-lib-2GP", | ||
"namespace": "adyen_payment", | ||
"sfdcLoginUrl": "https://login.salesforce.com", | ||
"sourceApiVersion": "60.0", | ||
"sourceApiVersion": "61.0", | ||
"packageAliases": { | ||
"API Library Apex Adyen": "0Ho4T0000000043SAA", | ||
"API Library Apex [email protected]": "04t4T000001VvbqQAC", | ||
|
@@ -22,6 +22,7 @@ | |
"API Library Apex [email protected]": "04tRP0000000A5pYAE", | ||
"API Library Apex [email protected]": "04tRP0000000D25YAE", | ||
"API Library Apex [email protected]": "04tRP0000000XGvYAM", | ||
"API Library Apex [email protected]": "04tRP0000000lwbYAA" | ||
"API Library Apex [email protected]": "04tRP0000000lwbYAA", | ||
"API Library Apex [email protected]": "04tRP0000000vZNYAY" | ||
} | ||
} |