
java基础问题
zhang_xin_new
这个作者很懒,什么都没留下…
展开
-
报异常抛出InvocationTargetException的解决方法
通常抛出InvocationTargetException 是NullPointerException 查看异常具体方法: 将鼠标放到catch 中的Exception ex 上 查看target中抛出的具体异常信息解决办法: 1.如果target中异常是找不到某个类 查看sql中返回的类 中字段是否与数据库中的字段一致 不一致 进行修改,修改方法如下例 2 . 如果所查原创 2017-07-08 17:46:52 · 65762 阅读 · 2 评论 -
【转载】cookies 揭秘
文章:作者:张子秋出处:http://www.cnblogs.com/zhangziqiu/ http://www.cnblogs.com/flyromance/articles/5027947.html1、什么是cookie cookie是 浏览器和服务器之间有约定:通过使用cookie技术来维护应用的状态转载 2017-07-21 20:12:14 · 360 阅读 · 0 评论 -
启动tomcat 报错ASM ClassReader failed to parse class file
.org.springframework.core.NestedIOException: ASM ClassReader failed to parse class file - probably due to a new Java class file version that isn't supported yet解决方法:1.首先尝试将Tomcat 8换成 7 ,问题没有解决原创 2017-12-01 09:41:05 · 842 阅读 · 0 评论 -
Spring MVC静态资源处理
转载:https://www.cnblogs.com/fangqi/archive/2012/10/28/2743108.html优雅REST风格的资源URL不希望带 .html 或 .do 等后缀.由于早期的Spring MVC不能很好地处理静态资源,所以在web.xml中配置DispatcherServlet的请求映射,往往使用 *.do 、 *.xhtml等方式。这就决定了请求URL转载 2017-12-01 10:47:29 · 225 阅读 · 0 评论 -
Invocation of init method failed; nested exception is java.lang.IllegalStateException:
异常 :Invocation of init method failed; nested exception is java.lang.IllegalStateException: Ambiguous mapping found. Cannot map '***Controller' bean method 原因 :controller 内的定义的url 重复原创 2017-11-23 17:53:15 · 39214 阅读 · 2 评论 -
时间时分秒后带.0格式化处理
解决: Unparseable date: "2018-09-11 11:12:23.0 用 DateFormat df = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss")格式化原创 2017-11-23 17:55:17 · 10261 阅读 · 2 评论 -
读zk 节点 报空指针
map 读zk 报空指针 查看application.xml 引用顺序 ,被其他类引用的放在最前面 如:××map.get("×key")bean id="××Props" class="ZookeeperConfigGroup"> constructor-arg name="configProfile" ref="××ConfigProfile" /> c原创 2017-11-23 18:09:53 · 813 阅读 · 0 评论 -
【转载】mybaits错误解决:There is no getter for property named 'id' in class 'java.lang.String'
转载链接:http://blog.youkuaiyun.com/aitcax/article/details/44337271在使用mybaitis传参数的时候,如果仅传入一个类型为String的参数,那么在 xml文件中应该使用_parameter来代替参数名。正确的写法:[html] view plain copysp转载 2017-11-23 18:15:55 · 778 阅读 · 0 评论 -
报错nested exception is org.springframework.core.NestedIOException: ASM ClassReader failed to...
原java7 换给java8后运行报错;nested exception is org.springframework.core.NestedIOException: ASM ClassReader failed to...org.springframework.beans.factory.BeanDefinitionStoreException: Failed to转载 2017-11-23 18:23:14 · 3938 阅读 · 0 评论