版權(quán)說(shuō)明:本文檔由用戶(hù)提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
ATM標(biāo)準(zhǔn)管理系統(tǒng)java窗口界面BAM銀行賬戶(hù)管理系統(tǒng)(ATM管理系統(tǒng))本系統(tǒng)采用JAVA語(yǔ)言并在eclipse環(huán)境下編寫(xiě)測(cè)試完成,涉及類(lèi)的概念,以及面向?qū)ο蟮膸状筇匦裕ɡ^承,封裝,多態(tài),抽象),也有異常處理機(jī)制,采用集合(更好)存儲(chǔ)賬戶(hù)數(shù)據(jù),基本可以滿(mǎn)足大多數(shù)BAM系統(tǒng)的相關(guān)實(shí)現(xiàn),且代碼內(nèi)標(biāo)注大量注釋?zhuān)x者可以很輕松地理解相關(guān)邏輯,大家可以開(kāi)心參考。系統(tǒng)簡(jiǎn)介:特點(diǎn):采用窗口界面風(fēng)格,而不是傳統(tǒng)的命令行、控制臺(tái)運(yùn)作模式1、JAVA類(lèi)的面相對(duì)象的應(yīng)用,擁有異常處理機(jī)制,不會(huì)因?yàn)檩斎脲e(cuò)誤而導(dǎo)致程序崩潰2、主要有7個(gè)類(lèi),即①Account(賬戶(hù)類(lèi))②SaveAccount(儲(chǔ)蓄賬戶(hù)類(lèi)):不能透支③CreditAccount(信用賬戶(hù)類(lèi)):可以透支④Bank(銀行類(lèi))⑤ATMOpenAccountFrame(開(kāi)戶(hù)窗口頁(yè)面)⑥ATMLoginFrame(登錄窗口頁(yè)面)⑦ATMMainFrame(操作窗口頁(yè)面) 帶有完善的相關(guān)信息提示彈出窗口見(jiàn)下面截圖 類(lèi)的具體屬性級(jí)行為見(jiàn)代碼 3、各個(gè)類(lèi)之間的相互關(guān)系,涉及繼承、封裝、多態(tài)、抽象,在多態(tài)中又涉及重載和重寫(xiě),請(qǐng)讀者注意相關(guān)聯(lián)系(關(guān)注注釋?zhuān)?4、可以實(shí)現(xiàn)數(shù)據(jù)保存功能,數(shù)據(jù)將保存在文件中(即當(dāng)你注冊(cè)了一個(gè)賬戶(hù),下次再登陸系統(tǒng)時(shí),可以實(shí)現(xiàn)與上次最后的操作相銜接) 5、賬戶(hù)號(hào)自動(dòng)生成,比較符合現(xiàn)實(shí) 6、主要功能有:1.開(kāi)戶(hù) 2.查詢(xún)賬戶(hù)余額 3.存款 4.取款 5.轉(zhuǎn)賬(一個(gè)賬戶(hù)到另一個(gè)賬戶(hù))等……7、運(yùn)行時(shí)界面簡(jiǎn)示 1.初始界面(賬戶(hù)登錄) 2.賬戶(hù)登錄后界面 3.相關(guān)信息提示一覽(只列舉一部分)1、查詢(xún): 2、存款:3、取款:4、轉(zhuǎn)賬:4、用戶(hù)開(kāi)戶(hù)界面:注意事項(xiàng):1、本系統(tǒng)采用的編程環(huán)境是JDK1.7,jer7。所以,運(yùn)行代碼需要保持電腦上所裝的JDK為1.7以上版本,如有報(bào)錯(cuò),只需換個(gè)高一點(diǎn)的版本即可。注意:第一次裝JDK,要配置環(huán)境變量(請(qǐng)查閱相關(guān)資料,比較簡(jiǎn)單)2、本系統(tǒng)代碼涉及到包,所以如果報(bào)名不一致就會(huì)報(bào)錯(cuò),解決方法:修改一下包名即可3、建議把各個(gè)類(lèi)寫(xiě)在同一個(gè)包下面,且每一個(gè)類(lèi)單獨(dú)寫(xiě)一個(gè)java文件,如下圖: 4、在運(yùn)行程序前,需要在項(xiàng)目下面新建一個(gè)account.txt(用來(lái)保存數(shù)據(jù))文件(如上圖),并在其中寫(xiě)入至少一個(gè)賬戶(hù)信息,(如下圖,其中每項(xiàng)代表的意思,請(qǐng)讀者參照代碼內(nèi)的注釋?zhuān)?,否則在初始化的時(shí)候會(huì)因?yàn)檎也坏劫~戶(hù)信息,從而產(chǎn)生異常。 系統(tǒng)源碼:Account類(lèi)packagecom.qx;importjavax.swing.JOptionPane;/***賬戶(hù)類(lèi):包含兩種賬戶(hù)類(lèi)型-->1.儲(chǔ)蓄賬戶(hù)2.信用賬戶(hù)*/publicabstractclassAccount{ //屬性 protectedlongid; protectedStringpassword; protectedStringname; protectedStringpersonId; protectedStringaccountType; protecteddoublebalance; //構(gòu)造方法 publicAccount(){ super(); } publicAccount(longid,Stringpassword,Stringname,StringpersonId, Stringtype,doublebalance){ super(); this.id=id; this.password=password; =name; this.personId=personId; this.accountType=type; this.balance=balance; } //getXxx,setXxx方法 publiclonggetId(){ returnid; } publicvoidsetId(longid){ this.id=id; } publicStringgetPassword(){ returnpassword; } publicvoidsetPassword(Stringpassword){ this.password=password; } publicStringgetName(){ returnname; } publicvoidsetName(Stringname){ =name; } publicStringgetPersonId(){ returnpersonId; } publicvoidsetPersonId(StringpersonId){ this.personId=personId; } publicStringgetAccountType(){ returnaccountType; } publicvoidsetAccountType(StringaccountType){ this.accountType=accountType; } publicdoublegetBalance(){ returnbalance; } publicvoidsetBalance(doublebalance){ this.balance=balance; } /** *存款 */ publicvoiddeposit(doublemoney){ balance+=money; } /** *取款(取款方式由賬戶(hù)類(lèi)型決定,所以設(shè)為抽象方法,相應(yīng)的Account類(lèi)應(yīng)設(shè)為抽象類(lèi)) */ publicabstractvoidwithdraw(doublemoney); }SavingAccount類(lèi)packagecom.qx;importjavax.swing.JOptionPane;/***儲(chǔ)蓄賬戶(hù)類(lèi)*/publicclassSavingAccountextendsAccount{ //構(gòu)造函數(shù) publicSavingAccount(){ super(); } publicSavingAccount(longid,Stringpassword,Stringname, StringpersonId,StringaccountType,doublebalance){ super(id,password,name,personId,accountType,balance); } //對(duì)父類(lèi)的withdraw()實(shí)現(xiàn) publicvoidwithdraw(doublemoney){ if(balance<money){ /*System.out.println("對(duì)不起,賬戶(hù)余額不足!");*/ JOptionPane.showMessageDialog(null,"對(duì)不起,賬戶(hù)余額不足!", "信息提示",JOptionPane.ERROR_MESSAGE); } else { balance-=money; } }}CresitAccount類(lèi)packagecom.qx;importjavax.swing.JOptionPane;/***信用賬戶(hù)類(lèi),增加一個(gè)信用額度ceiling屬性*/publicclassCreditAccountextendsAccount{ privateintceiling; //構(gòu)造函數(shù) publicCreditAccount(){ super(); } publicCreditAccount(longid,Stringpassword,Stringname, StringpersonId,StringaccountType,doublebalance,intceiling){ super(id,password,name,personId,accountType,balance); this.ceiling=ceiling; } //getXxx,setXxx方法 publicintgetCeiling(){ returnceiling; } publicvoidsetCeiling(intceiling){ this.ceiling=ceiling; } //實(shí)現(xiàn)父類(lèi)的withdraw() publicvoidwithdraw(doublemoney){ if((balance+ceiling)<money){ /*System.out.println("對(duì)不起,已超出您的信用額度!");*/ JOptionPane.showMessageDialog(null,"對(duì)不起,已超出您的信用額度!", "信息提示",JOptionPane.ERROR_MESSAGE); } else { balance-=money; } }}Bank類(lèi)packagecom.qx;importjava.io.BufferedReader;importjava.io.BufferedWriter;importjava.io.File;importjava.io.FileNotFoundException;importjava.io.FileReader;importjava.io.FileWriter;importjava.io.IOException;importjava.util.ArrayList;importjava.util.Iterator;importjava.util.List;importjava.util.Properties;importjavax.swing.JOptionPane;/***Bank類(lèi)*編寫(xiě)B(tài)ank類(lèi),屬性:1.當(dāng)前所有的賬戶(hù)對(duì)象的集合,存放在數(shù)組中2.當(dāng)前賬戶(hù)數(shù)量方法:1.用戶(hù)開(kāi)戶(hù),需要的參數(shù):id,密碼,密碼確認(rèn),姓名,身份證號(hào)碼,賬戶(hù)類(lèi)型,返回新創(chuàng)建的Account對(duì)象的賬號(hào),提示:用s1.equals(s2)可以比較s1,s2兩個(gè)字符串的值是否相等.賬戶(hù)類(lèi)型是一個(gè)整數(shù),為0的時(shí)候表示儲(chǔ)蓄賬戶(hù),為1的時(shí)候表示信用賬戶(hù)2.用戶(hù)登錄,參數(shù):id,密碼返回登錄賬戶(hù)的賬號(hào)3.用戶(hù)存款,參數(shù):id,存款數(shù)額,返回void4.用戶(hù)取款,參數(shù):id,取款數(shù)額,返回void5.查詢(xún)余額,參數(shù):id,返回該賬戶(hù)的余額double用戶(hù)會(huì)通過(guò)調(diào)用Bank對(duì)象以上的方法來(lái)操作自己的賬戶(hù),請(qǐng)分析各個(gè)方法需要的參數(shù)*/publicclassBank{ /*privateAccount[]accounts=newAccount[20];*/ privateListaccountsList; privateintnumber;//賬戶(hù)數(shù)目 privateintid=1001;//確定銀行賬號(hào)從1001開(kāi)始生成,即第一個(gè)賬戶(hù)的賬號(hào)是1001 //構(gòu)造函數(shù) publicBank(){ accountsList=newArrayList<Account>(); number=0; BufferedReaderbufReader=null; Propertiesprops=System.getProperties(); Stringpath=props.getProperty("user.dir"); try{ bufReader=newBufferedReader(newFileReader(newFile(path,"account.txt"))); Strings=bufReader.readLine(); while(s!=null){ String[]str=s.split(","); if(str[4].equals("0")) { AccountsavingAcc=newSavingAccount(Long.parseLong(str[0]), str[1].toString(),str[2].toString(), str[3].toString(),str[4].toString(), Double.parseDouble(str[5])); accountsList.add(savingAcc); } else { AccountcreditAcc=newCreditAccount(Long.parseLong(str[0]), str[1].toString(),str[2].toString(), str[3].toString(),str[4].toString(), Double.parseDouble(str[5]),5000); accountsList.add(creditAcc); } number++; id++; s=bufReader.readLine(); } }catch(NumberFormatExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); }catch(FileNotFoundExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); }catch(IOExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); }finally{ try{ if(bufReader!=null) { bufReader.close(); } }catch(IOExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); } } } //getXxx,setXxx publicListgetAccounts(){ returnaccountsList; } publicvoidsetAccounts(Listaccounts){ this.accountsList=accounts; } publicintgetNumber(){ returnnumber; } publicvoidsetNumber(intnumber){ this.number=number; } publicintgetId(){ returnid; } publicvoidsetId(intid){ this.id=id; } /** *開(kāi)戶(hù) */ publicAccountopenAccount(Stringpasswd1,Stringpasswd2,Stringname, StringpersonId,Stringtype){ //創(chuàng)建一個(gè)新賬戶(hù) Accountaccount=null; //判斷兩次密碼是否一致 if(passwd1.equals(passwd2)){ //若一致,再判斷賬戶(hù)類(lèi)型(根據(jù)type的值) if(type.equals("1")){ //可令開(kāi)始余額為10,信用額度為5000 account=newCreditAccount(id,passwd1,name,personId,type,10,5000); } else { account=newSavingAccount(id,passwd1,name,personId,type,10); } //將賬戶(hù)存入賬戶(hù)集合accountsList中 accountsList.add(account); JOptionPane.showMessageDialog(null,"開(kāi)戶(hù)成功!?。?,"信息提示", JOptionPane.INFORMATION_MESSAGE); JOptionPane.showMessageDialog(null,"您的卡號(hào)為:"+id+"\n"+ "您的密碼為:"+passwd1+"\n"+"您的戶(hù)名為:"+name+"\n"+ "您的身份證號(hào)為:"+personId+"\n"+"您的賬戶(hù)類(lèi)型為:"+type+"\n","信息提示", JOptionPane.INFORMATION_MESSAGE); account.accountType=type; number++; id++; returnaccount;//此時(shí)開(kāi)戶(hù)成功 } else { JOptionPane.showMessageDialog(null,"對(duì)不起!您兩次密碼輸入不匹配,開(kāi)戶(hù)失?。。?!", "信息提示",JOptionPane.ERROR_MESSAGE); returnnull;//此時(shí)開(kāi)戶(hù)失敗 } } /** *保存數(shù)據(jù) */ publicvoidsaveAccountDate(){ BufferedWriterbufWriter=null; try{ Propertiesprops=System.getProperties(); Stringpath=props.getProperty("user.dir"); Strings=null; bufWriter=newBufferedWriter(newFileWriter(newFile(path,"account.txt"))); for(Iteratoriterator=accountsList.iterator();iterator.hasNext();) { //若存在賬戶(hù) Accountacc=(Account)iterator.next(); //寫(xiě)入賬戶(hù)信息到account.txt bufWriter.write(acc.id+","); bufWriter.write(acc.getPassword()+","); bufWriter.write(acc.getName()+","); bufWriter.write(acc.getPersonId()+","); bufWriter.write(acc.getAccountType()+","); bufWriter.write(Double.toString(acc.getBalance())); bufWriter.newLine(); } bufWriter.flush();//清空緩存中的內(nèi)容 }catch(IOExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); }finally{ try{ if(bufWriter!=null){ bufWriter.close(); } }catch(IOExceptione){ //TODOAuto-generatedcatchblock e.printStackTrace(); } } } /** *登錄驗(yàn)證 */ publicAccountverifyAccount(longid,Stringpassword){ Accountaccount=null; Accountacc=null; for(Iteratoriterator=accountsList.iterator();iterator.hasNext();) { //若存在賬戶(hù) acc=(Account)iterator.next(); if(acc!=null){ if(id==acc.getId()&&password.equals(acc.getPassword())){ account=acc; break; } } else { break; } } returnaccount; } /** *轉(zhuǎn)賬驗(yàn)證(方法的重載) */ publicAccountverifyAccount(longid){ Accountaccount=null; Accountacc=null; for(Iteratoriterator=accountsList.iterator();iterator.hasNext();) { //若存在賬戶(hù) acc=(Account)iterator.next(); if(acc!=null){ if(id==acc.getId()){ account=acc; break; } } else { break; } } returnaccount; } /** *轉(zhuǎn)賬 */ publicvoidtransferAccount(Accountaccount1,Accountaccount2,doublemoney){ account1.withdraw(money); account2.deposit(money); } /** *存款 */ publicvoiddeposit(Accountaccount,doublemoney){ account.deposit(money); } /** *取款 */ publicvoidwithdraw(Accountaccount,doublemoney){ account.withdraw(money); } }ATMLoginFrame類(lèi)packagecom.qx;importjava.awt.Dimension;importjava.awt.GridLayout;importjava.awt.Toolkit;importjava.awt.event.ActionEvent;importjava.awt.event.ActionListener;importjavax.swing.JButton;importjavax.swing.JFrame;importjavax.swing.JLabel;importjavax.swing.JOptionPane;importjavax.swing.JPanel;importjavax.swing.JTextField;publicclassATMLoginFrameextendsJFrame{ privateJLabeljblCardNo,jblPasswd; privateJTextFieldjtfCardNo,jtfPasswd; privateJButtonjbOk,jbCancel,jbOpenAccount; privateJPaneljp1,jp2,jp3,jp4; privateBankbank; publicATMLoginFrame(){ bank=newBank(); //實(shí)例化所有組件 jblCardNo=newJLabel("用戶(hù)名:"); jblPasswd=newJLabel("密碼:"); jtfCardNo=newJTextField(20); jtfPasswd=newJTextField(20); jbOk=newJButton("確定"); jbCancel=newJButton("取消"); jbOpenAccount=newJButton("沒(méi)有賬戶(hù),開(kāi)戶(hù)"); jp1=newJPanel(); jp2=newJPanel(); jp3=newJPanel(); jp4=newJPanel(); jp1.add(jblCardNo); jp1.add(jtfCardNo); jp2.add(jblPasswd); jp2.add(jtfPasswd); jp3.add(jbOk); jp3.add(jbCancel); jp4.add(jbOpenAccount); //將每行逐行添加到frame中 this.add(jp1); this.add(jp2); this.add(jp3); this.add(jp4); this.setLayout(newGridLayout(4,1));//取消默認(rèn)管理器,設(shè)置為3行1列的網(wǎng)格布局 Dimensiond=Toolkit.getDefaultToolkit().getScreenSize(); this.setTitle("登陸界面"); this.setBounds((d.width-300)/2,(d.height-200)/2,300,200); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);//設(shè)置關(guān)閉窗口時(shí)JVM同時(shí)推出 this.pack();//調(diào)整窗口至能容納組件的最小尺寸 this.setVisible(true);//設(shè)置窗口可見(jiàn) this.setResizable(false);//不能最大化 //使用匿名內(nèi)部類(lèi)給2個(gè)按鈕注冊(cè)監(jiān)聽(tīng)器 jbCancel.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEvente){ dispose();//關(guān)閉窗口 } } ); jbOk.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEvente){ //取出用戶(hù)界面輸入的用戶(hù)名和密碼 longcardNo=Integer.parseInt(jtfCardNo.getText()); Stringpasswd=jtfPasswd.getText(); //調(diào)用Bank的相關(guān)方法將二者與正確的做比對(duì) Accountaccount=bank.verifyAccount(cardNo,passwd); if(account!=null)//假如正確,進(jìn)入操作界面 { ATMMainFramemainFrame=newATMMainFrame(bank,account);//進(jìn)入操作界面 dispose();//關(guān)閉登陸界面 }else{//假如錯(cuò)誤,使用對(duì)話(huà)框提示錯(cuò)誤信息 JOptionPane.showMessageDialog(null,"卡號(hào)或密碼錯(cuò)誤","信息提示",JOptionPane.ERROR_MESSAGE); } } } ); jbOpenAccount.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEventarg0){ ATMOpenAccountFrameopenFram=newATMOpenAccountFrame(); dispose();//關(guān)閉登陸界面 } } ); } /** *@paramargs */ publicstaticvoidmain(String[]args){ ATMLoginFrameatm=newATMLoginFrame(); }}ATMMainFrame類(lèi)packagecom.qx;importjava.awt.Dimension;importjava.awt.FlowLayout;importjava.awt.GridLayout;importjava.awt.Toolkit;importjava.awt.event.ActionEvent;importjava.awt.event.ActionListener;importjava.util.Scanner;importjavax.swing.JButton;importjavax.swing.JFrame;importjavax.swing.JLabel;importjavax.swing.JOptionPane;importjavax.swing.JPanel;publicclassATMMainFrameextendsJFrame{ privateAccountaccount; privateBankbank; privateJButtonjbDeposit,jbWithdraw,jbCancel,jbQuery,jbTransfer; privateJLabeljblMsg,jblName; privateJPaneljp1,jp2,jp3,jp4; /** *@paramargs */ publicATMMainFrame(finalBankbank,AccounttmpA){ this.account=tmpA; this.bank=bank; jbQuery=newJButton("查詢(xún)"); jbDeposit=newJButton("存款"); jbWithdraw=newJButton("取款"); jbTransfer=newJButton("轉(zhuǎn)賬"); jbCancel=newJButton("退卡"); jblName=newJLabel("賬戶(hù)姓名:"+account.getName()); jblMsg=newJLabel(); jp1=newJPanel(); jp2=newJPanel(); jp3=newJPanel(); jp4=newJPanel(); jp1.add(jbQuery); jp1.add(jbDeposit); jp2.add(jbWithdraw); jp2.add(jbTransfer); jp3.add(jbCancel); jp4.add(jblName); jp4.add(jblMsg); //將每行逐行添加到frame中 this.add(jp1); this.add(jp2); this.add(jp3); this.add(jp4); this.setLayout(newGridLayout(4,1));//取消默認(rèn)管理器,設(shè)置為4行1列的網(wǎng)格布局 Dimensiond=Toolkit.getDefaultToolkit().getScreenSize(); this.setTitle("操作界面"); this.setBounds((d.width-300)/2,(d.height-200)/2,300,200); this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);//設(shè)置關(guān)閉窗口時(shí)JVM同時(shí)推出 //this.pack();//調(diào)整窗口至能容納組件的最小尺寸 this.setVisible(true);//設(shè)置窗口可見(jiàn) this.setResizable(false); //使用匿名內(nèi)部類(lèi)給查詢(xún)按鈕注冊(cè)監(jiān)聽(tīng)器 jbQuery.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEvente){ JOptionPane.showMessageDialog(null,"您賬戶(hù)的當(dāng)前余額為:"+account.getBalance(), "信息提示",JOptionPane.INFORMATION_MESSAGE); } } ); //給存款按鈕注冊(cè)監(jiān)聽(tīng)器 jbDeposit.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEventarg0){ Strings=JOptionPane.showInputDialog("請(qǐng)輸入存款金額:"); doublemoney=Double.parseDouble((s.equals("")?"0":s)); bank.deposit(account,money); JOptionPane.showMessageDialog(null,"存款成功!??!","信息提示", JOptionPane.INFORMATION_MESSAGE); jblName=newJLabel("賬戶(hù)姓名:"+account.getName()); jblMsg.setText("余額:"+account.getBalance()); } } ); //給取款按鈕注冊(cè)監(jiān)聽(tīng)器 jbWithdraw.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEventarg0){ Strings=JOptionPane.showInputDialog("請(qǐng)輸入取款金額:"); doublemoney=Double.parseDouble((s.equals("")?"0":s)); bank.withdraw(account,money); /*JOptionPane.showMessageDialog(null,"取款成功?。?!","信息提示", JOptionPane.INFORMATION_MESSAGE);*/ jblName=newJLabel("賬戶(hù)姓名:"+account.getName()); jblMsg.setText("余額:"+account.getBalance()); } } ); //給轉(zhuǎn)賬按鈕注冊(cè)監(jiān)聽(tīng)器 jbTransfer.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEvente){ StringsId=JOptionPane.showInputDialog("請(qǐng)輸入要轉(zhuǎn)賬的卡號(hào):"); longid2=Long.parseLong(sId); Accountaccount2=bank.verifyAccount(id2); if(account2!=null) { StringsNum=JOptionPane.showInputDialog("請(qǐng)輸入您要轉(zhuǎn)入賬戶(hù)的金額:"); doublemoney=Double.parseDouble((sNum.equals("")?"0":sNum)); if(money<=account.balance) { bank.transferAccount(account,account2,money); JOptionPane.showMessageDialog(null,"轉(zhuǎn)賬成功!?。?,"信息提示", JOptionPane.INFORMATION_MESSAGE); } else { JOptionPane.showMessageDialog(null,"抱歉,您賬戶(hù)沒(méi)有足夠的金額!請(qǐng)查看后重新選擇輸入!", "信息提示",JOptionPane.ERROR_MESSAGE); } } else { JOptionPane.showMessageDialog(null,"抱歉,沒(méi)有找到您要轉(zhuǎn)入的賬戶(hù)信息!請(qǐng)核對(duì)后重新選擇輸入!","信息提示", JOptionPane.ERROR_MESSAGE); } jblName=newJLabel("賬戶(hù)姓名:"+account.getName()); jblMsg.setText("余額:"+account.getBalance()); } } ); //給退卡按鈕注冊(cè)監(jiān)聽(tīng)器 jbCancel.addActionListener( newActionListener(){ publicvoidactionPerformed(ActionEvente){ bank.saveAccountDate(); dispose();//關(guān)閉窗口 } } ); } }ATMOpenAccountFrame類(lèi)packagecom.qx;importjava.awt.Dimension;importjava.awt.GridLayout;importjava.awt.Toolkit;importjava.awt.event.ActionEvent;importjava.awt.event.ActionListener;importjavax.swing.JButton;importjavax.swing.JFrame;importjavax.swing.JLabel;importjavax.swing.JPanel;importjavax.swing.JTextField;p
溫馨提示
- 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶(hù)所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶(hù)上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶(hù)上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶(hù)因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 信息軟件公司關(guān)聯(lián)交易管理制度版本
- 物流倉(cāng)庫(kù)安全檢查及整改方案
- 財(cái)務(wù)部年度預(yù)算編制及控制方案
- 2026年數(shù)字貨幣對(duì)零售行業(yè)影響報(bào)告
- 集團(tuán)年度人才盤(pán)點(diǎn)工作實(shí)施方案
- 2026年西藥執(zhí)業(yè)藥師資格考試藥品不良反應(yīng)報(bào)告流程測(cè)驗(yàn)試卷
- 三八趕?;顒?dòng)策劃方案(3篇)
- 意面套餐活動(dòng)方案策劃(3篇)
- 應(yīng)急預(yù)案需要資料(3篇)
- 基礎(chǔ)電力施工方案(3篇)
- 北京市東城區(qū)2025-2026學(xué)年高三上學(xué)期期末考試英語(yǔ) 有答案
- 2025年煤礦安全規(guī)程新增變化條款考試題庫(kù)及答案
- 2025年教師師德師風(fēng)自查問(wèn)題清單及整改措施范文
- 2026年廣東農(nóng)墾火星農(nóng)場(chǎng)有限公司公開(kāi)招聘作業(yè)區(qū)管理人員備考題庫(kù)及參考答案詳解
- 國(guó)家電投集團(tuán)江蘇公司招聘筆試題庫(kù)2026
- 養(yǎng)老護(hù)理服務(wù)的法律監(jiān)管與執(zhí)法
- 中國(guó)地級(jí)市及各省份-可編輯標(biāo)色地圖
- 實(shí)驗(yàn)室生物安全培訓(xùn)-課件
- 第章交流穩(wěn)態(tài)電路
- 預(yù)應(yīng)力管樁-試樁施工方案
- FZ/T 82006-2018機(jī)織配飾品
評(píng)論
0/150
提交評(píng)論