pstmt = conn.prepareStatement("select ordernumber,datetime,price,dayofmoney from zujie where ordernumber= "+ cdName + " ") rs=pstmt.executeQuery() if(rs!=null && rs.next()){ String datetime = rs.getString(2) java.text.SimpleDateFormat formatter = new java.text.SimpleDateFormat ("yyyy-MM-dd") Date date = new Date() String date1=formatter.format(date) ParsePosition pos = new ParsePosition(0) ParsePosition pos1 = new ParsePosition(0) Date dt1=formatter.parse(datetime,pos) Date dt2=formatter.parse(date1,pos1) Long l = (dt2.getTime()-dt1.getTime())/(3600*24*1000)+1 double price = rs.getDouble(3) double dayofmoney=rs.getDouble(4) double dayofmoneybuy=dayofmoney*l double otherMoney = price-dayofmoneybuy request.setAttribute("price", price) request.setAttribute("l", l) request.setAttribute("dayofmoney", dayofmoneybuy) request.setAttribute("otherMoney", otherMoney)
標簽: prepareStatement ordernumber dayofmoney datetime
上傳時間: 2013-12-14
上傳用戶:zsjinju
51單片連tcs230的源程序,絕對原創,可以記憶顏色。 #define uchar unsigned char #include <reg52.h> #include<math.h> sbit S0=P1^7 sbit S1=P1^0 //端口定義 sbit S2=P1^1 sbit S3=P1^2 sbit OE=P1^3 sbit OUT=P3^4 //頻率從TO口輸入 sbit key0=P1^5 sbit LED=P1^6 sbit a=P3^0 sbit b=P3^1 uchar color //1:blue 2:green 3:red uchar T[4] //color timer uchar TH[4] uchar TL[4] uchar bizhi[4] void time1() interrupt 3 { TH[color]=TH0 TL[color]=TL0 T[color]=(TH[color]*0xff+TL[color]) TR0=0 //關定時器 TR1=0 TH1=0xB1 TL1=0xE0 //歸0 TH0=0x00 TL0=0x00 //歸0 }
上傳時間: 2016-11-26
上傳用戶:秦莞爾w
The DHRY program performs the dhrystone benchmarks on the 8051. Dhrystone is a general-performance benchmark test originally developed by Reinhold Weicker in 1984. This benchmark is used to measure and compare the performance of different computers or, in this case, the efficiency of the code generated for the same computer by different compilers. The test reports general performance in dhrystones per second. Like most benchmark programs, dhrystone consists of standard code and concentrates on string handling. It uses no floating-point operations. It is heavily influenced by hardware and software design, compiler and linker options, code optimizing, cache memory, wait states, and integer data types. The DHRY program is available in different targets: Simulator: Large Model: DHRY example in LARGE model for Simulation Philips 80C51MX: DHRY example in LARGE model for the Philips 80C51MC
標簽: general-performanc benchmarks Dhrystone dhrystone
上傳時間: 2016-11-30
上傳用戶:hphh
Boost provides free peer-reviewed portable C++ source libraries. We emphasize libraries that work well with the C++ Standard Library. Boost libraries are intended to be widely useful, and usable across a broad spectrum of applications. The Boost license encourages both commercial and non-commercial use. We aim to establish "existing practice" and provide reference implementations so that Boost libraries are suitable for eventual standardization. Ten Boost libraries are already included in the C++ Standards Committee s Library Technical Report (TR1) as a step toward becoming part of a future C++ Standard. More Boost libraries are proposed for the upcoming TR2. Boost works on almost any modern operating system, including UNIX and Windows variants. Follow the Getting Started Guide to download and install Boost. Popular Linux and Unix distributions such as Fedora, Debian, and NetBSD include pre-built Boost packages. Boost may also already be available on your organization s internal web server.
標簽: libraries peer-reviewed emphasize provides
上傳時間: 2016-12-05
上傳用戶:semi1981
樹狀目錄結構,帶有源碼。分為不同的類,可獨自運行,也可插入其它框架中,代碼實現了文件路徑以string存取
上傳時間: 2013-11-29
上傳用戶:wkchong
1.1 數據庫還原和配置 在MS SQL里創建數據庫,使用壓縮包里的oom.sql語句還原或oom.db數據庫備份文件還原。使用SQL語句還原時會提示錯誤可忽略。 Dimconn.asp文件為數據庫配置文件。 1.2 生成文件目錄屬性及模版 Inc.asp和include.asp:目錄設置。 Filelist.asp:859行“/news/”為預覽目錄 xinwen.html:新聞發布模版頁 topic.html:專題發布模版頁 1.3 腳本引用 focusad.asp:專題引用腳本 web_adduilian.asp:對聯廣告腳本 web_file.asp:內容引用腳本 參數:listID目錄ID;ListCount顯示條數;Bgcolor背景色;ListSize顯示字符串長度;title顯示標題 webfilemore.html:內容更多頁 調用:webfilemore.html?ListID=&DetailSize= 參數:ListID目錄ID;DetailSize寬度 1.4 初始管理員和密碼: 帳號:admin 密碼:
上傳時間: 2016-12-12
上傳用戶:pkkkkp
The XC226x derivatives are high-performance members of the Infineon XC2000 Family of full-feature single-chip CMOS microcontrollers. These devices extend the functionality and performance of the C166 Family in terms of instructions (MAC unit), peripherals, and speed. They combine high CPU performance (up to 80 million instructions per second) with extended peripheral functionality and enhanced IO capabilities. Optimized peripherals can be adapted flexibly to meet the application requirements. These derivatives utilize clock generation via PLL and internal or external clock sources. Onchip memory modules include program Flash, program RAM, and data RAM.
標簽: high-performance full-feature derivatives Infineon
上傳時間: 2016-12-12
上傳用戶:wab1981
Skype4Java開發指南 Skype4Java架構 Skype4Java提供了一個較為完善的開發體系,使您可以非常容易地使用Java開發Skype外殼程序。 Skype插件程序與Skype的通信都是基于一些文本命令來完成的。因此,要想開發Skype的插件應用,就需要依靠不同操作系統平臺的系統調用,發送Skype平臺的相應命令來實現。 Skype4Java在最底層,也是通過操作系統的系統調用來完成消息的發送。針對異構平臺,Skype4Java提供了不同平臺的底層實現,而Skype4Java的使用者不用管具體的操作系統平臺。因為抽象父類Connector類的靜態方法getInstance()具體判斷當前操作系統是什么平臺,采用簡單的工廠模式,返回相應平臺的子類對象,如OSXConnector.,LinuxConnector, WindowsConnector, Win32Connector等,這些都是Connector類的子類。Connector及其子類即實現了一些系統調用的方法,其中被重載的一系列execute()方法最終調用不同子類的sendCommand (String command)方法來實現了不同平臺的消息發送。 而對于一些數據的接收和處理全局都是采用事件監聽的機制(觀察者模式),用于完成數據的接收,處理機制的調用,錯誤的處理等。 Skype平臺利用錯誤消息機制提供了出錯的處理。因此,在我們的錯誤處理中,只需分析錯
標簽: Skype4Java 開發指南 架構
上傳時間: 2014-11-28
上傳用戶:manlian
在C++中open一個output file有兩種方式,一種是使用member function open( ),另外一種是使用constructor給予檔案名稱和open mode。今若欲open一個名為client.dat的output file,試分別寫出該兩種方式open此檔案的statements.(包括include header file,物件的宣告,open指令等)
上傳時間: 2016-12-21
上傳用戶:wxhwjf
gcclib This gcc 1.40 suits for Linux kernel 0.11 - 0.95 Installtion hints ----------------- This suit contains include.taz, local.taz and this README file. You must download the bootimage and rootimage and install them first. The include.taz contains all the include files for using with gcc 1.40. The local.taz contains all the gcc tools & libs stored in two sepearted directories: /usr/local/lib /usr/local/bin You should copy the linux/ asm/ sys/ subdirectories into the include directory from the corresponding kernel source. Installation ------------ Goto the /usr directory. Untar the include.taz to the directory /usr/include. Untar the local.taz to the directory /usr/local. That s it! Example: -------- cd /usr tar zxvf include.taz tar zxvf local.taz
標簽: Installtion gcclib kernel Linux
上傳時間: 2014-03-12
上傳用戶:源碼3