/**
 * @author student
/*******************************************************************************
 * Copyright (c) 2003 Clearfield Knowledge Solutions.
 * All rights reserved. This program and the accompanying materials 
 * are made available under the terms of the Common Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.k.co.nz/
 *******************************************************************************/
/* * 
 * Copyright: Copyright (c) 2003
 * Company  : Clearfield Knowledge Solutions
 * @author  : Student
 * @version : 1.0
 * Date Created : Jul 8, 2003
 * Title : JavaBean.CreditCard_Data.java
 * Desprition : This JavaBean class is responsible for getting and setting
 * properties realted to Credit card Data .
 * 
 */
package JavaBeans;

/**
 * @author student
 *
 * This class is being used as a java bean for storing the credit card details.
 * 
 */
public class CreditCard_Data {

	private String cardType;
	private String cardHolderName;
	private String cardNumber;
	private String expiryDate;

	private String month;
	private String year;


	/**
	 * This is the constructor for CreditCard_Data.java
	 */
	public CreditCard_Data() {
	}

	/**
	 * This is the constructor for CreditCard_Data.java
	 */
	public CreditCard_Data(
		String cardType,
		String cardHolderName,
		String cardNumber,
		String expiryDate) {
		this.cardType = cardType;
		this.cardHolderName = cardHolderName;
		this.cardNumber = cardNumber;
		this.expiryDate = expiryDate;
	}
	
	/**
	 * This method is being used for setting the cardtype field.
	 * @param cardType Card type.
	 * @return void
	 */
	public void setCardType(String cardType) {
		this.cardType = cardType;
	}
	
	/**
	 * This method is being used for setting the cardHolderName field.
	 * @param cardHolderName The card holder name.
	 * @return void
	 */
	public void setCardHolderName(String cardHolderName) {
		this.cardHolderName = cardHolderName;
	}
	
	
	/**
	 * This method is being used for setting the cardNumber field.
	 * @param cardNumber The credit card number.
	 * @return void
	 */
	public void setCardNumber(String cardNumber) {
		this.cardNumber = cardNumber;
	}
	
	
	/**
	 * This method is being used for setting the expiryDate field.
	 * @param expiryDate The credit card expiry date.
	 * @return void
	 */
	public void setExpirydate(String expiryDate) {
		this.expiryDate = expiryDate;
	}
	
	
	/**
	 * This method is being used for getting the cardType field.
	 * @return String The card type.
	 */
	public String getCardType() {
		return this.cardType;
	}
	
	/**
	 * This method is being used for getting the cardHolderName field.
	 * @return String The credit card holder name.
	 */
	public String getCardHolderName() {
		return this.cardHolderName;
	}
	
	/**
	 * This method is being used for getting the cardNumber field.
	 * @return String The credit card number.
	 */
	public String getCardNumber() {
		return this.cardNumber;
	}
	
	
	/**
	 * This method is being used for getting the expiryDate field.
	 * @return String The credit card expiry date.
	 */
	public String getExpiryDate() {
		expiryDate = month + year;
		return this.expiryDate;
	}
	
	
	/**
	 * This method is being used for setting the month field.
	 * @param month The credit card expiry month.
	 * @return void 
	 */
	public void setMonth(String month) {
		this.month = month;
	}
	
	
	/**
	 * This method is being used for getting the month field.
	 * @return String The credit card expiry month.
	 */
	public String getMonth() {
		return this.month;
	}
	
	
	/**
	 * This method is being used for setting the year field.
	 * @param year The credit card expiry year.
	 * @return void
	 */
	public void setYear(String year) {
		this.year = year;
	}
	
	
	/**
	 * This method is being used for getting the year field.
	 * @return String The credit card expiry year.
	 */
	public String getYear() {
		return this.year;
	}
}