Monday, February 9, 2009

/*Programmer:Miexie D. Tulid
*Title:Form of Payment class*/


public class FormofPayment
{

private int checkno;
private int cardno;
private String expiredate;
private String fpay;

public FormofPayment(String fpayment,int creditno,String xdate)
{
fpay=fpayment;
cardno=creditno;
expiredate= xdate;
}
public FormofPayment(int chek,String xdate)
{
checkno=chek;
expiredate= xdate;
}


public String verifyCardno(int newcardno)
{
if(cardno==newcardno){
return String.format("Ok");}

else{

return String.format("Not");}
}

public String verifyChekPayment(int newcheckno)
{
if(checkno==newcheckno){

return String.format("Ok");}

else{

return String.format("Not");}
}
}

No comments:

Post a Comment