1.在命令行状态下进入到包含cscope.out的目录下。或者你认为合适的路径下。(前提是当前的路径到cscope.out的路径中间别再包含空格了)
2.subst x: .
3.就完成了当前路径映射到x:盘符的操作了。
4.加载的时候直接加载x:\cscope.out就可以了。
1.找到工程下struts2-dojo-plugin-2.1.6.jar这个包。
2.用winrar或者7zip打开。进入:struts2-dojo-plugin-2.1.6.jar\org\apache\struts2\static\dojo\nls\找个路径下,看到dojo_zh.js和dojo_zh-cn.js这两个文件。
3.拖出来,用utf-8的格式打开。怎么改大家一看就知道了。
4.把修改后的文件替换回去。就可以了。
ii.dojo_zh.js的正确内容如下:
dojo.provide("nls.dojo_zh");dojo.provide("dojo.i18n.calendar.nls.gregorian");dojo.i18n.calendar.nls.gregorian._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorian.zh");dojo.i18n.calendar.nls.gregorian.zh={"days-standAlone-narrow":["日","一","二","三","四","五","六"],"eras":["公元前","公元"],"am":"上午","months-format-abbr":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"days-format-abbr":["周日","周一","周二","周三","周四","周五","周六"],"pm":"下午","months-format-wide":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"months-standAlone-narrow":["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],"days-format-wide":["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],"field-weekday":"Day of the Week","dateFormat-medium":"yyyy MMM d","field-second":"Second","field-week":"Week","timeFormat-full":"HH:mm:ss z","field-year":"Year","field-minute":"Minute","timeFormat-medium":"HH:mm:ss","field-hour":"Hour","dateFormat-long":"yyyy MMMM d","field-day":"Day","field-dayperiod":"Dayperiod","field-month":"Month","dateFormat-short":"yy/MM/dd","field-era":"Era","timeFormat-short":"HH:mm","timeFormat-long":"HH:mm:ss z","dateFormat-full":"EEEE, yyyy MMMM dd","field-zone":"Zone"};dojo.provide("dojo.i18n.calendar.nls.gregorianExtras");dojo.i18n.calendar.nls.gregorianExtras._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorianExtras.zh");dojo.i18n.calendar.nls.gregorianExtras.zh={"dateFormat-yearOnly":"yyyy'年'"};dojo.provide("dojo.i18n.calendar.nls.gregorian");dojo.i18n.calendar.nls.gregorian._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorian.zh");dojo.i18n.calendar.nls.gregorian.zh={"days-standAlone-narrow":["日","一","二","三","四","五","六"],"eras":["公元前","公元"],"am":"上午","months-format-abbr":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"days-format-abbr":["周日","周一","周二","周三","周四","周五","周六"],"pm":"下午","months-format-wide":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"months-standAlone-narrow":["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],"days-format-wide":["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],"field-weekday":"Day of the Week","dateFormat-medium":"yyyy MMM d","field-second":"Second","field-week":"Week","timeFormat-full":"HH:mm:ss z","field-year":"Year","field-minute":"Minute","timeFormat-medium":"HH:mm:ss","field-hour":"Hour","dateFormat-long":"yyyy MMMM d","field-day":"Day","field-dayperiod":"Dayperiod","field-month":"Month","dateFormat-short":"yy/MM/dd","field-era":"Era","timeFormat-short":"HH:mm","timeFormat-long":"HH:mm:ss z","dateFormat-full":"EEEE, yyyy MMMM dd","field-zone":"Zone"};dojo.provide("dojo.widget.nls.TimePicker");dojo.widget.nls.TimePicker._built=true;dojo.provide("dojo.widget.nls.TimePicker.zh");dojo.widget.nls.TimePicker.zh={"any":"any"};dojo.provide("dojo.widget.nls.DropdownTimePicker");dojo.widget.nls.DropdownTimePicker._built=true;dojo.provide("dojo.widget.nls.DropdownTimePicker.zh");dojo.widget.nls.DropdownTimePicker.zh={"selectTime":"Select time"};dojo.provide("dojo.widget.nls.DropdownDatePicker");dojo.widget.nls.DropdownDatePicker._built=true;dojo.provide("dojo.widget.nls.DropdownDatePicker.zh");dojo.widget.nls.DropdownDatePicker.zh={"selectDate":"Select a date"};
iii.dojo_zh-cn.js的内容如下:
dojo.provide("nls.dojo_zh-cn");dojo.provide("dojo.i18n.calendar.nls.gregorian");dojo.i18n.calendar.nls.gregorian._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorian.zh_cn");dojo.i18n.calendar.nls.gregorian.zh_cn={"dateFormat-medium":"yyyy-M-d","field-second":"秒钟","field-week":"周","timeFormat-full":"ahh'时'mm'分'ss'秒' z","field-year":"年","field-minute":"分钟","timeFormat-medium":"ahh:mm:ss","field-hour":"小时","dateFormat-long":"yyyy'年'M'月'd'日'","field-day":"日","field-dayperiod":"上午/下午","field-month":"月","dateFormat-short":"yy-M-d","field-era":"时期","timeFormat-short":"ah:mm","timeFormat-long":"ahh'时'mm'分'ss'秒'","dateFormat-full":"yyyy'年'M'月'd'日'EEEE","field-weekday":"周天","field-zone":"区域","days-standAlone-narrow":["日","一","二","三","四","五","六"],"eras":["公元前","公元"],"am":"上午","months-format-abbr":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"days-format-abbr":["周日","周一","周二","周三","周四","周五","周六"],"pm":"下午","months-format-wide":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"months-standAlone-narrow":["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],"days-format-wide":["星期日","星期一","星期二","星期三","星期四","星期五","星期六"]};dojo.provide("dojo.i18n.calendar.nls.gregorianExtras");dojo.i18n.calendar.nls.gregorianExtras._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorianExtras.zh_cn");dojo.i18n.calendar.nls.gregorianExtras.zh_cn={"dateFormat-yearOnly":"yyyy'年'"};dojo.provide("dojo.i18n.calendar.nls.gregorian");dojo.i18n.calendar.nls.gregorian._built=true;dojo.provide("dojo.i18n.calendar.nls.gregorian.zh_cn");dojo.i18n.calendar.nls.gregorian.zh_cn={"dateFormat-medium":"yyyy-M-d","field-second":"秒钟","field-week":"周","timeFormat-full":"ahh'时'mm'分'ss'秒' z","field-year":"年","field-minute":"分钟","timeFormat-medium":"ahh:mm:ss","field-hour":"小时","dateFormat-long":"yyyy'年'M'月'd'日'","field-day":"日","field-dayperiod":"上午/下午","field-month":"月","dateFormat-short":"yy-M-d","field-era":"时期","timeFormat-short":"ah:mm","timeFormat-long":"ahh'时'mm'分'ss'秒'","dateFormat-full":"yyyy'年'M'月'd'日'EEEE","field-weekday":"周天","field-zone":"区域","days-standAlone-narrow":["日","一","二","三","四","五","六"],"eras":["公元前","公元"],"am":"上午","months-format-abbr":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"days-format-abbr":["周日","周一","周二","周三","周四","周五","周六"],"pm":"下午","months-format-wide":["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],"months-standAlone-narrow":["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],"days-format-wide":["星期日","星期一","星期二","星期三","星期四","星期五","星期六"]};dojo.provide("dojo.widget.nls.TimePicker");dojo.widget.nls.TimePicker._built=true;dojo.provide("dojo.widget.nls.TimePicker.zh_cn");dojo.widget.nls.TimePicker.zh_cn={"any":"any"};dojo.provide("dojo.widget.nls.DropdownTimePicker");dojo.widget.nls.DropdownTimePicker._built=true;dojo.provide("dojo.widget.nls.DropdownTimePicker.zh_cn");dojo.widget.nls.DropdownTimePicker.zh_cn={"selectTime":"Select time"};dojo.provide("dojo.widget.nls.DropdownDatePicker");dojo.widget.nls.DropdownDatePicker._built=true;dojo.provide("dojo.widget.nls.DropdownDatePicker.zh_cn");dojo.widget.nls.DropdownDatePicker.zh_cn={"selectDate":"Select a date"};
1.下载cygwin(windows下虚拟unix的软件),并安装。下载及安装的方法见网上的帖子。
2.下载mysql-1.4.x.tar.gz复制到/home下。
3.tar -zxvf mysql-xx.tar.gz等等。安装mysql。
4.下载freeradius的windows版本。安装。
5.配置freeradius让freeradius支持mysql。
6.运行mysql服务,并登陆。完成对mysql数据库的配置。
7.运行freeradius服务。
8.完成。
有问题请留意。
如果想在oracle里自己手动建立数据库的话,找在 开始菜单-->程序-->oracle-oraHomexx-->Configuration and Migration Tools--->Database Configuration Assistant。 这个程序是编辑数据库的工具,可以添加,删除,配置数据库,建立模板等等。
取得com端口的id-->端口的引用,一定要在得到SerialPort以后添加事件的触发条件.
例如:
port.notifyOnDataAvailable(true);
port.notifyOnBreakInterrupt(true);
port.notifyOnCarrierDetect(true);
port.notifyOnCTS(true);
port.notifyOnDataAvailable(true);
port.notifyOnDSR(true);
port.notifyOnFramingError(true);
port.notifyOnOutputEmpty(true);
port.notifyOnOverrunError(true);
port.notifyOnParityError(true);
port.notifyOnRingIndicator(true);
3;7fc710e3;
license.id = free
license.version.major = 6
license.user = free
license.org = free
license.lastUpdate = forever
license.expiration = forever
license.edition = controlcenter
license.hostid = anyHostId
license.numofinstances = 1000
license.alternative = false
1首先要有相应的jdbc
2.用tomcat的控制台配置数据源。
3.到tomcat/conf下添加context。xml
内容如下:<Context>
<WatchedResource>WEB-INF/web.xml</WatchedResource>
<Resource name="jdbc/mysql" type="javax.sql.DataSource" password="sa" driverClassName="com.mysql.jdbc.Driver" maxIdle="2" maxWait="5000" username="root" url="jdbc:mysql://127.0.0.1/test" maxActive="4" />
</Context>
4。配置你相应的项目的web。xml添加:
<resource-ref>
<description>DB Connection</description>
<res-ref-name>jdbc/mysql</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
<res-sharing-scope>Shareable</res-sharing-scope>
</resource-ref>
Ok!
从c:\dowm\sljl\aa.xml-转化为aa.xml
for(int i = name.length();i>0;i--){
if(((int)name.charAt(i-1))==92){
fileName = name.substring(i,name.length());
break;
}
}
哎哟.我晕了.天太热了.小小的servlet竟然让我翻船.兄弟,如果你没有ide的话,你能顺利写下servlet的程序吗???
InputStream in = getClass().getResourceAsStream("/properties/jdbc.properties");
Properties pro= new Properties();
try {
pro.load(in);
} catch (IOException e) {
e.printStackTrace();
}
return pro.getProperty(name);
先读取当前路径下的(文件或者路径).然后读进属性类里.
今天写一小段测试程序.如下:
List list = new ArrayList();
list .add(1,"aa");
list.add(2,"bb");
System.out.println(list.get(1));
抛出异常:java.lang.IndexOutOfBoundsException: Index: 1, Size: 0
at java.util.ArrayList.add(Unknown Source)
at test.Test.testDate(Test.java:74)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:478)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:344)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
原因:缺少list.add(0,"sfsdfsda");