0% found this document useful (0 votes)
23 views1 page

Code Challenge: Program 3:you

The document outlines a code challenge to design a class structure for a payment gateway system. There should be four classes: PaymentGateway, which uses methods from CreditCard; CreditCard, which defines four pure virtual methods; and MasterCard and VisaCard, which inherit from CreditCard. The goal is to create the class structures that can successfully compile, without implementing the method processing details.

Uploaded by

aedira poojitha
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
23 views1 page

Code Challenge: Program 3:you

The document outlines a code challenge to design a class structure for a payment gateway system. There should be four classes: PaymentGateway, which uses methods from CreditCard; CreditCard, which defines four pure virtual methods; and MasterCard and VisaCard, which inherit from CreditCard. The goal is to create the class structures that can successfully compile, without implementing the method processing details.

Uploaded by

aedira poojitha
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

Code challenge

Program 3:You
details.
need to design a class structure referring to the following

The Payment Gateway companies make use of APIs offered by the Credit Card companies. There are two main card
types which are offered to the customers are Master and Visa. Although the cards offer different facilities but the
API methods called by the Payment Gateway companies are standardized (thus need to have same name and
parameters but can have different processing details). However the methods for customer dealings are all specific to
the card types this means they can differ in their name and numbers for individual card types.
You need to make the four classes as follows
1. PaymentGateway - The class uses the methods offerred by CreditCard class while they interact with customers.
2. CreditCard : It offers four pure virtual methods – cardAuthent(), getInvDetails(), processInvoices(),
UpdateAccount()
3. MasterCard : Inherits CreditCard class
4. VisaCard: Inherits CreditCard class
You are supposed to make only the class structures and successfully compile them. None of the methods need to
have any details of actual processing (methods details may be highly complicated).

You might also like