26
2020
05

Java8新特性视频教程

 该教程的主要内容包括以下内容:
1.Lambda表达式
2.函数式接口
3.方法引用与构造器引用
4.Stream API
5.接口中的默认方法与静态方法
6.新时间日期API
7.其他新特性


26
2020
05

最新全套尚硅谷SpringCloud视频教程

 尚硅谷SpringCloud视频教程是一款尚硅谷SpringCloud视频教程大全,给未来需要的你,本套视频从面试题,到SpringCloud各种核心组件,到最终的微服务架构总结,帮助大家快速入门、上手并精通微服务框架SpringCloud。

25
2020
05

idea 大小都提示设置

intellij idea默认下的代码提示是区分大小写的,通过设置可以不区分大小写进行提示.


第一步:选择File->Setting


第二步:找到 Editor->General->Code Completion 


第三步:取消Match case前的勾选保存即可。


25
2020
05

Error creating bean with name 'commonsMultipartResolver': Lookup method resolution failed解决方法

 org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'commonsMultipartResolver': Lookup method resolution failed; nested exception is java.lang.IllegalStateException: Failed to introspect Class [org.springframework.web.multipart.commons.CommonsMultipartResolver] from ClassLoader [jdk.internal.loader.ClassLoaders$AppClassLoader@78308db1]

25
2020
05

Error creating bean with name 'jsonMessageConverter': Failed to introspect bean class解决方法

Error creating bean with name 'jsonMessageConverter': Failed to introspect bean class出现这个错误是因为:

 缺少jackson依赖

25
2020
05

Constructor threw exception; nested exception is java.lang.NoClassDefFoundEr的解决方法

 Constructor threw exception; nested exception is java.lang.NoClassDefFoundEr

Constructor threw exception; nested exception is java.lang.NoClassDefFoundError: com/fasterxml/jackson/databind/exc/InvalidDefinitionException的根本原因在于jar包

25
2020
05

@webappconfiguration注解

 

  • Spring @WebAppConfiguration Annotation Example

25
2020
05

SpringMVC@ContextConfiguration注解详解

 

@ContextConfiguration这个注解通常与@RunWith(SpringJUnit4ClassRunner.class)联合使用用来测试

当一个类添加了注解@Component,那么他就自动变成了一个bean,就不需要再Spring配置文件中显示的配置了。把这些bean收集起来通常有两种方式,Java的方式和XML的方式。当这些bean收集起来之后,当我们想要在某个测试类使用@Autowired注解来引入这些收集起来的bean时,只需要给这个测试类添加@ContextConfiguration注解来标注我们想要导入这个测试类的某些bean。

25
2020
05

org.apache.ibatis.type.TypeException: Could not resolve type alias 'WithDeptResultMap'

 Caused by: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias 'WithDeptResultMap'.  Cause: java.lang.ClassNotFoundException: Cannot find class: WithDeptResultMap
 at org.apache.ibatis.builder.BaseBuilder.resolveClass(BaseBuilder.java:100)
 at org.apache.ibatis.builder.xml.XMLStatementBuilder.parseStatementNode(XMLStatementBuilder.java:69)
 at org.apache.ibatis.builder.xml.XMLMapperBuilder.buildStatementFromContext(XMLMapperBuilder.java:132)
 at org.apache.ibatis.builder.xml.XMLMapperBuilder.buildStatementFromContext(XMLMapperBuilder.java:125)
 at org.apache.ibatis.builder.xml.XMLMapperBuilder.configurationElement(XMLMapperBuilder.java:115)
 ... 44 more
Caused by: org.apache.ibatis.type.TypeException: Could not resolve type alias 'WithDeptResultMap'.  Cause: java.lang.ClassNotFoundException: Cannot find class: WithDeptResultMap
 at org.apache.ibatis.type.TypeAliasRegistry.resolveAlias(TypeAliasRegistry.java:114)
 at org.apache.ibatis.builder.BaseBuilder.resolveAlias(BaseBuilder.java:127)
 at org.apache.ibatis.builder.BaseBuilder.resolveClass(BaseBuilder.java:98)
 ... 48 more
Caused by: java.lang.ClassNotFoundException: Cannot find class: WithDeptResultMap
 at org.apache.ibatis.io.ClassLoaderWrapper.classForName(ClassLoaderWrapper.java:188)
 at org.apache.ibatis.io.ClassLoaderWrapper.classForName(ClassLoaderWrapper.java:87)
 at org.apache.ibatis.io.Resources.classForName(Resources.java:254)
 at org.apache.ibatis.type.TypeAliasRegistry.resolveAlias(TypeAliasRegistry.java:110)
 ... 50 more

25
2020
05

log4j:WARN No appenders could be found for logger (org.springframework.test.context.junit4.SpringJUn

SSM整合,在进行单元测试时,会报下面的警告。

log4j:WARN No appenders could be found for logger (org.springframework.test.context.junit4.SpringJUnit4ClassRunner).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.