-
大小: 1.85MB文件類型: .zip金幣: 2下載: 0 次發(fā)布日期: 2023-08-11
- 語言: Java
- 標(biāo)簽: java??汽車出租??mysql??管理系統(tǒng)??
資源簡介
使用Java語言+MySQL數(shù)據(jù)庫實(shí)現(xiàn),有Java工程和MySQL腳本,分別將工程導(dǎo)入就能使用。這是一個(gè)很好的學(xué)習(xí)系統(tǒng),汽車出租管理系統(tǒng)

代碼片段和文件信息
package?Guanliyuan;
import?java.awt.BorderLayout;???//供容器進(jìn)行東西南北中區(qū)域布局
import?java.awt.Color;
import?java.awt.HeadlessException;???????//異常,當(dāng)一個(gè)依賴于鍵盤(顯示器或鼠標(biāo)的代碼被調(diào)用時(shí),在不支持鍵盤、顯示器或鼠標(biāo)的環(huán)境中調(diào)用)
import?java.awt.event.ActionEvent;???????//事件
import?java.awt.event.ActionListener;????????//事件的監(jiān)視,只有public?void?actionPerformed(ActionEvent?e)方法
import?java.sql.Connection;??????????????????//數(shù)據(jù)庫連接
import?java.sql.DriverManager;???????????????//JDBK驅(qū)動程序引用
import?java.sql.ResultSet;???????????????????//數(shù)據(jù)庫查詢結(jié)果的數(shù)據(jù)表
import?java.sql.SQLException;????????????????//數(shù)據(jù)庫訪問錯(cuò)誤或其他錯(cuò)誤時(shí)提供信息異常
import?java.sql.Statement;???????????????????//執(zhí)行靜態(tài)SQL語句并返回產(chǎn)生的結(jié)果
import?javax.swing.Box;?????????????????//Box盒式容器
import?javax.swing.JButton;???????????//按鈕的實(shí)現(xiàn)
import?javax.swing.Jframe;??????????//窗口
import?javax.swing.JLabel;??????//一個(gè)短文本字符串或圖像的顯示區(qū)域標(biāo)簽
import?javax.swing.JOptionPane;????//彈出對話框(提示用戶輸入一個(gè)值或其他事件)
import?javax.swing.JPanel;????????//面板,可添加組建,可添加到容器中,默認(rèn)FlowLayout布局
import?javax.swing.JScrollPane;????//滾動視圖
import?javax.swing.JTable;?????????//表格組建?????????
import?javax.swing.JTextField;?????//輸入單行文字
import?Index.*;??????????
public?class?Guanliyuan?extends?Jframe?implements?ActionListener{????//繼承Jframe窗體類,實(shí)現(xiàn)動作監(jiān)聽接口
/**
?*?
?*/
private?static?final?long?serialVersionUID?=?1L;
/*
?*?
?*?管理員端的界面
?*/
JTable?table;
JLabel?label1label2label3label4;
object?a[][];
object?name[]?=?{“編號““車型““車主““價(jià)格(元/天)““顏色““是否被租用““租用的用戶“};
JButton?buttonOfXinxilurubuttonOfXinxiliulanbuttonOfDeletebuttonOfLogoutbuttonOfXiangXibuttonOfXiugai;??//聲明對象
Box?box1box2;
JTextField?fieldfield2field3;
JPanel?jPanel4jPanel5;
Connection?con?=?null;
Statement?stmt?=?null;
ResultSet?rs?=?null;
public?Guanliyuan(boolean?b)????//構(gòu)造方法
{
init();?
setVisible(true);????//窗口可見(Jframe類)
// setDefaultCloseOperation(Jframe.EXIT_ON_CLOSE);
setBounds(500?200?625?490);????//設(shè)置窗口在屏幕上的位置及大小
settitle(“管理員界面“);?????//標(biāo)題
if(true)//successs是一個(gè)boolean類型,如果為true,打開此窗口直接信息瀏覽,false表示里面沒有信息,需要點(diǎn)擊信息瀏覽
{???????//successs改為true
xinXiLiuLan();
}
}
void?init()
{
label1?=?new?JLabel(“汽車租賃信息管理系統(tǒng)“);???//創(chuàng)建一個(gè)具有指定文本?JLabel實(shí)例,標(biāo)簽
label1.setForeground(new?Color(13843226));
buttonOfXinxiluru?=?new?JButton(“??汽車信息錄入??“);???//創(chuàng)建一個(gè)帶有文本的按鈕
buttonOfXinxiluru.setBackground(new?Color(149101177));
buttonOfXinxiluru.setForeground(new?Color(225227230));
buttonOfXinxiluru.addActionListener(this);????????????//監(jiān)聽
buttonOfXinxiliulan?=?new?JButton(“??汽車信息瀏覽??“);
buttonOfXinxiliulan.setBackground(new?Color(149101177));
buttonOfXinxiliulan.setForeground(new?Color(225227230));
buttonOfXinxiliulan.addActionListener(this);
buttonOfDelete?=?new?JButton(“????刪 ????????????除??????“);
buttonOfDelete.setBackground(new?Color(149101177));
buttonOfDelete.setForeground(new?Color(225227230));
buttonOfDelete.addActionListener(this);
buttonOfLogout?=?new?JButton(“??退???出???登???錄??“);
butt
?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-10-30?16:29??1615070232?韋富齡?汽車出租管理程序\
?????文件????????2602??2018-06-27?14:06??1615070232?韋富齡?汽車出租管理程序\car_rental.sql
?????文件?????1009984??2018-06-27?23:11??1615070232?韋富齡?汽車出租管理程序\汽車出租管理系統(tǒng).jar
?????目錄???????????0??2018-10-30?16:34??1615070232?韋富齡?汽車出租管理程序\源碼\
?????文件?????????380??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\.classpath
?????文件?????????378??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\.project
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\.settings\
?????文件?????????598??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\.settings\org.eclipse.jdt.core.prefs
?????目錄???????????0??2018-10-30?16:50??1615070232?韋富齡?汽車出租管理程序\源碼\bin\
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\
?????文件????????8860??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\Guanliyuan.class
?????文件????????6822??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\Luru.class
?????文件????????5530??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\Xiangxi.class
?????文件????????2137??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\Xinxitijiao.class
?????文件????????7429??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Guanliyuan\Xiugai.class
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Index\
?????文件????????6371??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Index\Login.class
?????文件?????????450??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Index\StartMain.class
?????文件????????5724??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Index\Zhuce.class
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Yonghu\
?????文件????????4757??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Yonghu\Xiangxi_yonghu.class
?????文件???????10217??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\bin\Yonghu\Yonghuduan.class
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\libs\
?????文件??????972009??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\libs\mysql_connector_java_5.1.36_bin.jar
?????目錄???????????0??2018-10-27?22:12??1615070232?韋富齡?汽車出租管理程序\源碼\src\
?????目錄???????????0??2018-07-18?11:25??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\
?????文件???????11452??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\Guanliyuan.java
?????文件????????7044??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\Luru.java
?????文件????????4838??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\Xiangxi.java
?????文件????????1988??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\Xinxitijiao.java
?????文件????????7810??2018-06-27?23:13??1615070232?韋富齡?汽車出租管理程序\源碼\src\Guanliyuan\Xiugai.java
............此處省略7個(gè)文件信息
評論
共有 條評論