24-07-2012, 11:50 AM
Credit Card Validation System
creditcard validation final ppt (1).ppt (Size: 748.5 KB / Downloads: 38)
Introduction
A quick reminder: Modulo Operation
Credit Card Validation implementation using Luhn Algorithm
Programming Language: Java
Graphical User Interface (GUI): Java Swing
2 Modules: Algorithm Implementation & GUI
Output:
Entered Credit Card Number Valid or not
Type of Credit Card (Visa, MasterCard etc…)
Algorithm Implementation
public static void main(String[] args)
{
CreditCardValidator validator = new CreditCardValidator();
boolean validated = validator.validateCardNumber("49927398716", VISA);
System.out.println(validated);
}
1 Main Class: CreditCardValidator()
Various Methods:
ValidateNumber(): Validates the number combination
validateCardNumber(): Verifies the type of the credit card
Above code used to manually test logic
GUI (Java Swing)
Swing – Widget toolkit for Java
Extended Learnt Principles of Java Swing to Develop GUI for this project
Java Swing widely used for GUIs
2 tired application as Logic & GUI layers not interdependent
Platform Independence – GUI accessible on any platform – a big plus!
Lessons Learnt
Planning / Scheduling plays a critical role
Prior knowledge helped
Essential to develop & test algorithm before developing code
Team work requires proper co-ordination
More exposure to coding and projects will aid in adapting to the ever changing field of Information Technology