freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

精品--基于java的qq聊天工具的設(shè)計(jì)與實(shí)現(xiàn)-資料下載頁(yè)

2024-12-06 03:27本頁(yè)面

【導(dǎo)讀】Java技術(shù)的合理應(yīng)用能實(shí)現(xiàn)跨平臺(tái)的網(wǎng)絡(luò)通訊。線程等技術(shù),依靠強(qiáng)大的跨平臺(tái)開發(fā)軟件,以當(dāng)今流行的QICQ為模板,仿照QICQ設(shè)計(jì)出簡(jiǎn)單而實(shí)用的、具有基本聊天功能的、基于JAVA的聊天工具。設(shè)計(jì)和主要功能模塊的工作原理及其圖解。在文中提供了部分功能模塊實(shí)現(xiàn)的源代。最后,本文還粗略地探討了軟件的測(cè)試用例設(shè)計(jì)和完成此次設(shè)計(jì)的心得體會(huì)。

  

【正文】 )。 (400,400)。 Dimension screenSize=().getScreenSize()。 int screenWidth=。 int screenHeight=。 Dimension frameSize=()。 int x=()/2。 int y=()/2。 (x,y)。 (false)。 (true)。 } else{ //不在線,留言 } ()。 ()。 ()。 }catch(IOException e12){ (e12)。} ()。 4 聊天消息的接受功能的部分代碼如下 //發(fā)送消息響應(yīng)事件 int r_no =(().trim())。 int s_no = myQno。 String s_petname = myPetname。 String s_ip = myip。 String r_petname = ().toString().trim()。 String s_str = ().trim()。 //創(chuàng)建消息包 String r_IP = ().trim()。 Message s_mess = new Message(r_no, r_petname,s_petname,s_no, s_str, s_ip,r_IP)。 //發(fā)送消息包 Socket connectToServer = new Socket(, 5001)。 // Create an input stream to receive data from the server DataInputStream isFromServer = new DataInputStream( ())。 // Create an output stream to send data to the server DataOutputStream osToServer = new DataOutputStream(())。 ObjectOutputStream sout = new ObjectOutputStream(osToServer)。 try { (s_mess)。 ()。 } catch(IOException e1) { (e1)。 } } catch (IOException ex) { (ex)。 } //將發(fā)送消息添加到聊天記錄中 String str_qno_time = myQno+( +myPetname+)+ ++\n。 (str_qno_time)。 (s_str+\n)。 ()。 5 服務(wù)器端 功能的部分代碼如下 else if((black)) { try{ ()。 Connection c4=(jdbc:odbc:BasicInfo, , )。 //以下連接好友表,返回用戶的好友名單 String friend=select blackqno from blacklists where myqno=?。 PreparedStatement prepare4=(friend)。 ()。 int icqno=(())。 // (wqecdd)。 (1,icqno)。 ResultSet r4=()。 Vector friendno=new Vector()。//該矢量保存好友號(hào)碼 while(()){ (new Integer((1)))。 } ()。 //read friend info //以下告訴客戶其黑名單的呢稱等個(gè)人信息 // (())。 for(int i=0。i()。i++){ String friendinfo=select petname,qnum,ip,status,picindex,mail from personalinfo where qnum=?。 PreparedStatement prepare5=(friendinfo)。 ()。 (1,(i))。 ResultSet r5=()。 boolean status。 while(()){ // ((petname))。 ((petname))。 ((qnum))。 ((ip))。 status=(status)。 if (status)(1)。 else{(0)。} ((picindex))。 ((mail))。 } //while ()。 }//for //發(fā)送完畢 (over)。 (over)。 ()。 // ()。 }catch (Exception e) {()。(false)。} //:登陸界面代碼: package Myjava_。 import .*。 import .*。 import 。 import .*。 import .*。 import 。 import 。 import 。 import 。 import .*。 import .*。 import .*。 class Imagecanvas extends Canvas { Toolkit tool。 Image myimage。 Imagecanvas() { setSize(326,47)。 tool=getToolkit()。 myimage=()。 } public void paint(Graphics g) { (myimage,0,0,326,47,this)。 } } //class Paii5 extends JFrame implements ActionListener class Paii5 extends JFrame { Paii5() { setResizable(false)。 //Frame fra=new Frame(2021)。 //setSize(330,240)。 setBounds(350, 300, 330,240)。 Container c=getContentPane()。 //(new FlowLayout(100,100,10))。 FlowLayout layout=new FlowLayout()。 JPanel p1=new JPanel()。 JPanel p2=new JPanel()。 JPanel p3=new JPanel()。 JPanel p4=new JPanel()。 ImageIcon image=new ImageIcon(getClass().getResource(/image/))。//創(chuàng)建一個(gè)未初始化的圖像圖標(biāo) JLabel jl5=new JLabel(image)。//entry Imagecanvas canvas1=new Imagecanvas()。 //(326,47)。 //(canvas1)。 final JTextField username=new JTextField(11)。 final TextField paword=new TextField(15)。 (39。*39。)。 JButton buttonentrystu=new JButton(申請(qǐng)?zhí)柎a )。 JButton buttonentryteacher=new JButton(高級(jí)設(shè)置 )。 JButton buttonentryadmin=new JButton(登 錄 )。 JButton buttonreset=new JButton(取 消 )。 JCheckBox check1=new JCheckBox(自動(dòng)登陸 )。 JCheckBox check2=new JCheckBox(隱身登陸 )。 JPanel p21=new JPanel()。 JPanel p22=new JPanel()。 (new JLabel( 號(hào)碼 :))。 (username)。 (buttonentrystu)。 (new JLabel( 密碼 :))。 (paword)。 (new JLabel(htmlfont color=blue忘記密碼 ?/fonthtml))。 (new JLabel( ))。 (new JLabel( ))。 (check1)。 (check2)。 (new JLabel( ))。 (jl5)。 (p4,)。 (buttonentryteacher)。 (new JLabel( ))。 (buttonentryadmin)。 (new JLabel( ))。 (buttonreset)。 (p21)。 (p22)。 (150,300, 200, 300)。 (new GridLayout(2,1,10,10))。 (400,100)。 (new JLabel(htmlfont color=006600 建筑學(xué)院 蘭志杰 /font/html))。//設(shè)置字體顏色 setLayout(new BorderLayout())。 add(,p4)。 add(,p2)
點(diǎn)擊復(fù)制文檔內(nèi)容
研究報(bào)告相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1