JSP学术会议论文系统投稿及审稿(任务书+开题报告+源程序)
rs = stmt.executeQuery(sql);
return rs;
} catch (Exception e) {
System.err.println(e.getMessage());
e.printStackTrace();
}
return null;
}
public Statement getStmt//取得stmt
{
try { con = getCon();
stmt = con.createStatement();
return stmt;
} catch (Exception e) {
System.err.println(e.getMessage());
e.printStackTrace();
}
return null;
}
(2)Data.java相关函数
public int getRowCount(String strSql) {
int intCount = 0;
try {
stmt = con.getStmtread();
rs = stmt.executeQuery("SELECT COUNT(*) FROM " + strSql);
if (rs.next()) {
intCount = rs.getInt(1);
} else {
intCount = -1;
}
} catch (Exception e) {
intCount = -2;
System.err.println(e.getMessage());
e.printStackTrace();
} finally {
con.close();
return intCount;
}
}
(3)Str.java相关函数
public String toChinese(String str) {
www.751com.cn return str;
}
(4)upLoadFile.java相关函数
public upBean() {
m_files = new files();
m_totalBytes = 0;
m_currentIndex = 0;
m_startData = 0;
m_endData = 0;
m_boundary = new String();
m_totalMaxFileSize = 0L;
m_maxFileSize = 0L;
m_allowedExtList = new Vector();
m_allowedFileTypeList = new Vector();
m_formRequest = new Request();
m_count = 0;
isCover = true;
realPath = new String();
}
public final void initialize(PageContext pagecontext)
throws ServletException {
m_application = pagecontext.getServletContext();
m_request = (HttpServletRequest) pagecontext.getRequest();
m_response = (HttpServletResponse) pagecontext.getResponse();
}
public void setAllowedExtList(String s) {
String s1 = "";
if (s != null) {
String s2 = "";
for (int i = 0; i < s.length(); i++)
if (s.charAt(i) == ',') {
if (!m_allowedExtList.contains(s2))
m_allowedExtList.addElement(s2);
s2 = "";
} else {
s2 = s2 + s.charAt(i);
}
if (s2 != "")
m_allowedExtList.addElement(s2);
} else {
m_allowedExtList = null;
}
}
private String getFileExt(String s) {
<< 上一页 [11] [12] [13] [14] [15] [16] [17] 下一页
JSP学术会议论文系统投稿及审稿(任务书+开题报告+源程序+答辩PPT) 第16页下载如图片无法显示或论文不完整,请联系qq752018766