昨天写了段代码,用Calendar.getInstance().get(Calendar.MONTH)去取月份。明明是四月,却显示了“3”,纳闷!后来在Calendar.java看到这段:
看来还是多看点文档好啊。
昨天写了段代码,用Calendar.getInstance().get(Calendar.MONTH)去取月份。明明是四月,却显示了“3”,纳闷!后来在Calendar.java看到这段:
catalina 主要脚本,控制Tomcat调用
cpappend 设置classpath环境变量
digest 生成加密的密码
jasper JavaServer Pages编译器脚本
jspc 调用jasper的jspc参数
setclasspath 设置classpath环境变量
shutdown 停止Tomcat,调用“catalina stop”
starup 启动Tomcat,调用“catalina start”
tool-wrapper 供digest调用
这两天快被Tomcat搞死了, 一直连不上Oracle。结果今天在台湾的JavaWorld看到网友指点,在Apache的网站上找到了下面这段:
These jar files along with your the jar file for your JDBC driver should be installed in $CATALINA_HOME/common/lib.
NOTE:Third Party drivers should be in jarfiles, not zipfiles. Tomcat only adds $CATALINA_HOME/common/lib/*.jar to the classpath.
另外,如果是Oracle 9i,要用ojdbc14.jar。NOTE: Do not install these jarfiles in your /WEB-INF/lib, or $JAVA_HOME/jre/lib/ext, or anywhere else. You will experience problems if you install them anyplace other than $CATALINA_HOME/common/lib.
因为开始学Java了,总是要看《The Java(TM) Tutorial》的。当我看到“How Do These Concepts Translate into Code?”时,就发现有问题了。在源代码ClickMe.java中就写错了,有一部分直径变量RADIUS竟然小写成“radius”了。已经向SUN反馈了。
BTW:其实这个程序还有一个问题,就是.setLayout和.add要分别改成.contentPane.setLayout和.contentPane.add。
Get free blog up and running in minutes with Blogsome
Theme designed by Dave Shea