資源簡(jiǎn)介
java javafx 界面開(kāi)發(fā) 選課 系統(tǒng) ,帶設(shè)計(jì)文檔說(shuō)明,UI設(shè)計(jì)齊全,直接拿來(lái)用

代碼片段和文件信息
/*
?*?To?change?this?template?choose?Tools?|?Templates
?*?and?open?the?template?in?the?editor.
?*/
package?org.tjumyk;
import?com.sun.deploy.uitoolkit.impl.fx.ui.FXAboutDialog;
import?java.util.logging.Level;
import?java.util.logging.Logger;
import?javafx.application.Platform;
/**
?*
?*?@author?E40-G8C
?*/
public?abstract?class?BackgroundRunner?{
????private?boolean?waitForeground?=?false;
????/**
?*?@tag?label
?*?name?=?“Abstract“
?*/
????public?abstract?void?background()?throws?Exception;
????public?void?foreground()?throws?Exception?{
????}
????public?abstract?void?handleException(Exception?e)?throws?Exception;
????public?abstract?void?finish()?throws?Exception;
????protected?final?void?runForeground()?{
????????waitForeground?=?true;
????????Platform.runLater(new?Thread()?{
????????????@Override
????????????public?void?run()?{
????????????????try?{
????????????????????foreground();
????????????????}?catch?(Exception?ex)?{
????????????????????try?{
????????????????????????handleException(ex);
????????????????????}?catch?(Exception?ex1)?{
????????????????????????ex1.printStackTrace();
????????????????????}
????????????????}
????????????????waitForeground?=?false;
????????????}
????????});
????????while?(waitForeground)?{
????????????try?{
????????????????Thread.sleep(10);
????????????}?catch?(InterruptedException?ex)?{
????????????????ex.printStackTrace();
????????????}
????????}
????}
????private?void?handleExceptionInFxThread(final?Exception?e)?{
????????Platform.runLater(new?Thread()?{
????????????@Override
????????????public?void?run()?{
????????????????try?{
????????????????????handleException(e);
????????????????}?catch?(Exception?ex)?{
????????????????????ex.printStackTrace();
????????????????}
????????????}
????????});
????}
????public?final?void?run()?{
????????new?Thread()?{
????????????@Override
????????????public?void?run()?{
????????????????try?{
????????????????????background();
????????????????????Platform.runLater(new?Thread()?{
????????????????????????@Override
????????????????????????public?void?run()?{
????????????????????????????try?{
????????????????????????????????finish();
????????????????????????????}?catch?(Exception?ex)?{
????????????????????????????????try?{
????????????????????????????????????handleException(ex);
????????????????????????????????}?catch?(Exception?ex1)?{
????????????????????????????????????ex1.printStackTrace();
????????????????????????????????}
????????????????????????????}
????????????????????????}
????????????????????});
????????????????}?catch?(final?Exception?e)?{
????????????????????handleExceptionInFxThread(e);
????????????????}
????????????}
????????}.start();
????}
}
?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2012-06-06?18:04??Databa
?????文件?????????539??2012-06-04?08:28??Databa
?????文件?????????510??2012-06-04?08:26??Databa
?????文件????????3734??2012-06-01?15:30??Databa
?????文件????????1247??2012-06-03?18:10??Databa
?????目錄???????????0??2012-06-04?07:04??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件???????22335??2012-06-01?15:30??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件???????73526??2012-06-01?15:30??Databa
?????文件??????120640??2012-06-01?15:30??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件??????424758??2012-06-01?15:30??Databa
?????文件??????141185??2012-06-01?15:30??Databa
?????文件??????253160??2012-06-01?15:30??Databa
?????文件??????785998??2011-02-08?18:25??Databa
?????文件?????????540??2012-06-01?15:30??Databa
?????文件??????584207??2012-02-29?17:11??Databa
?????文件??????????85??2012-06-01?15:30??Databa
?????文件????????8779??2012-06-03?15:05??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件???????78502??2012-06-01?15:30??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件???????????0??2012-06-04?10:12??Databa
?????文件???????????0??2012-06-04?10:12??Databa
?????文件?????????475??2012-06-01?15:30??Databa
?????文件??????122379??2012-06-01?15:30??Databa
?????目錄???????????0??2012-06-01?16:04??Databa
?????目錄???????????0??2012-06-01?15:30??Databa
?????文件?????????204??2012-06-04?10:12??Databa
?????文件?????????203??2012-06-04?10:12??Databa
............此處省略46個(gè)文件信息
評(píng)論
共有 條評(píng)論