91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 67KB
    文件類型: .rar
    金幣: 2
    下載: 1 次
    發(fā)布日期: 2021-12-09
  • 語言: Java
  • 標簽:

資源簡介

Java約瑟夫環(huán)演示Applet源碼,程序組成:
  MainApplet類:主要實現(xiàn)了界面的顯示
  MainSrc類:主要實現(xiàn)了界面圖形變化的控制
  ParaDialog類:實現(xiàn)了測試參數(shù)的輸入

資源截圖

代碼片段和文件信息

package?josephus;

import?java.awt.*;
import?java.awt.event.*;
import?java.applet.*;
import?java.awt.Rectangle;
import?java.awt.Font;
import?java.awt.BorderLayout;
import?java.awt.LayoutManager;
import?javax.swing.*;
import?javax.swing.border.*;
import?java.net.URL;
import?java.awt.event.ActionEvent;
import?javax.swing.Timer;

/**
?*?

title:?Josephus


?*
?*?

Description:?This?is?a?algorithm?to?display?Josephus


?*
?*?

Copyright:?Copyright?(c)?2007


?*
?*?

Company:?BHL


?*?Download?by?http://www.codesc.net
?*?@author?Linpeizhong
?*?@version?1.0
?*/

/**
?*?界面類,設計之初添加其為實現(xiàn)接口ActionListener,為定時器的實現(xiàn)做為前提
?*/
public?class?Mainapplet
????extends?applet
????implements?ActionListener?{
??//聲明定時器對象
??javax.swing.Timer?timer;

??//定義測試對象數(shù)組
??int?n?=?12;
??int?a[]?=?new?int[n];

??//初始密碼
??int?cs?=?20;

??//標簽數(shù)組
??JLabel?jLabels[]?=?new?JLabel[n];

??//密碼標簽
??String?strs[]?=?new?String[n];

??//是否獨立運行
??boolean?isStandalone?=?false;
??//布局管理器
??BorderLayout?borderLayout1?=?new?BorderLayout();
??BorderLayout?borderLayout2?=?new?BorderLayout();
??BorderLayout?borderLayout3?=?new?BorderLayout();
??BorderLayout?borderLayout5?=?new?BorderLayout();
??BorderLayout?borderLayout6?=?new?BorderLayout();

??//面板
??JPanel?jPanel1?=?new?JPanel();
??JPanel?jPanel2?=?new?JPanel();
??JPanel?jPanel3?=?new?JPanel();
??JPanel?jPanel4?=?new?JPanel();
??JPanel?jPanel5?=?new?JPanel();
??JPanel?jPanel6?=?new?JPanel();

??//邊線
??Border?border1?=?BorderFactory.createEtchedBorder(EtchedBorder.RAISEDColor.white?new?Color(165?163?151));
??Border?border2?=?new?titledBorder(border1?“演示窗口“);?//Get?a?parameter?value
??Border?border3;
??Border?border4;
??Border?border5;
??Border?border6;
??Border?border7;

??//按鈕
??JButton?jButton1?=?new?JButton();
??//?設置為靜態(tài),供外部程序控制
??static?JButton?jButton2?=?new?JButton();
??JButton?jButton4?=?new?JButton();

??//聲明組件,加載相關圖片
??Image?images[];
??JLabel?jLabel3;
??JLabel?jLabel4;
??JLabel?jLabel5;
??JLabel?jLabel6;
??JLabel?jLabel7;
??JLabel?jLabel8;
??JLabel?jLabel9;
??JLabel?jLabel10;
??JLabel?jLabel11;
??JLabel?jLabel12;
??JLabel?jLabel13;
??JLabel?jLabel14;

??//密碼標簽
??JLabel?ms[]?=?new?JLabel[n];
??JLabel?m1?=?new?JLabel();
??JLabel?m2?=?new?JLabel();
??JLabel?m3?=?new?JLabel();
??JLabel?m4?=?new?JLabel();
??JLabel?m5?=?new?JLabel();
??JLabel?m6?=?new?JLabel();
??JLabel?m7?=?new?JLabel();
??JLabel?m8?=?new?JLabel();
??JLabel?m9?=?new?JLabel();
??JLabel?m10?=?new?JLabel();
??JLabel?m11?=?new?JLabel();
??JLabel?m12?=?new?JLabel();


??//獲取參數(shù)
??public?String?getParameter(String?key?String?def)?{
????return?isStandalone???System.getProperty(key?def)?:
????????(getParameter(key)?!=?null???getParameter(key)?:?def);
??}

??//applet的構造器
??public?Mainapplet()?{
??}

??//初始化applet
??public?void?init()?{
????try?{
??????jbInit();
????}
????catch?(Exception?e)?{
??????e.printStackTrace();
????}
??}

??//面板初始化

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----

?????文件???????2363??2007-12-31?01:25??codesc.net\Josephus\image\1.jpg

?????文件???????2333??2007-12-31?01:33??codesc.net\Josephus\image\10.jpg

?????文件???????2459??2007-12-31?01:34??codesc.net\Josephus\image\11.jpg

?????文件???????3091??2007-12-31?01:35??codesc.net\Josephus\image\12.jpg

?????文件???????2287??2007-12-31?01:28??codesc.net\Josephus\image\2.jpg

?????文件???????2219??2007-12-31?01:28??codesc.net\Josephus\image\3.jpg

?????文件???????2629??2007-12-31?01:29??codesc.net\Josephus\image\4.jpg

?????文件???????2231??2007-12-31?01:30??codesc.net\Josephus\image\5.jpg

?????文件???????2794??2007-12-31?01:31??codesc.net\Josephus\image\6.jpg

?????文件???????2782??2007-12-31?01:31??codesc.net\Josephus\image\7.jpg

?????文件???????2356??2007-12-31?01:32??codesc.net\Josephus\image\8.jpg

?????文件???????2640??2007-12-31?01:33??codesc.net\Josephus\image\9.jpg

?????文件????????697??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet$1.class

?????文件??????19121??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet.class

?????文件??????27827??2015-01-27?11:22??codesc.net\Josephus\josephus\Mainapplet.java

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jButton1_actionAdapter.class

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jButton2_actionAdapter.class

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jButton4_actionAdapter.class

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jButton5_actionAdapter.class

?????文件????????498??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jSlider1_mouseMotionAdapter.class

?????文件????????498??2008-01-13?16:10??codesc.net\Josephus\josephus\Mainapplet_jSlider2_mouseMotionAdapter.class

?????文件???????2769??2008-01-13?16:10??codesc.net\Josephus\josephus\MainSrc.class

?????文件???????4518??2015-01-27?11:22??codesc.net\Josephus\josephus\MainSrc.java

?????文件????????390??2008-01-13?16:10??codesc.net\Josephus\josephus\Node.class

?????文件??????10516??2008-01-13?16:10??codesc.net\Josephus\josephus\ParaDialog.class

?????文件??????16523??2015-01-27?11:22??codesc.net\Josephus\josephus\ParaDialog.java

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\ParaDialog_jButton1_actionAdapter.class

?????文件????????520??2008-01-13?16:10??codesc.net\Josephus\josephus\ParaDialog_jButton2_actionAdapter.class

?????文件????????850??2007-12-26?02:11??codesc.net\Josephus\Josephus.html

?????文件????????392??2007-12-31?19:41??codesc.net\Josephus\Mainapplet.html

............此處省略8個文件信息

評論

共有 條評論