samedi 20 juin 2015

Best pattern to be used for multiple payment gateways

Requirement:

I have requirement to integration with multiple payment gateways. However the client uses only one of the available, and that is configured using admin settings.

Current System:

I have written one library each per payment gateway. Which creates a maintenance nightmare and potential increase in projects as the gateway integration requests (sources) increase.

Question

Can someone suggest me a design pattern to use in this scenario, to may be create interfaces and common settings and implement the gateway as required which reduces duplicate code?

Aucun commentaire:

Enregistrer un commentaire