导入jfinal-2.2-lib和jfinal-2.2-src源码启动报错

牢记签名十八字 发布于 2016/11/15 13:56
阅读 100
收藏 0

@JFinal 你好,想跟你请教个问题:

导入jfinal-2.2-lib和jfinal-2.2-src到工程中然后配置好相关信息在启动服务时报

2016-11-15 13:53:09 [ main:1 ] - [ ERROR ] Internal FreeMarker error: java.lang.ClassCastException: freemarker.cache.WebappTemplateLoader cannot be cast to freemarker.cache.TemplateLoader
java.lang.RuntimeException: Internal FreeMarker error: java.lang.ClassCastException: freemarker.cache.WebappTemplateLoader cannot be cast to freemarker.cache.TemplateLoader
at freemarker.template.Configuration.setServletContextForTemplateLoading(Configuration.java:478)
at com.jfinal.render.FreeMarkerRender.init(FreeMarkerRender.java:87)
at com.jfinal.render.RenderFactory.initFreeMarkerRender(RenderFactory.java:107)
at com.jfinal.render.RenderFactory.init(RenderFactory.java:75)
at com.jfinal.core.JFinal.initRender(JFinal.java:95)
at com.jfinal.core.JFinal.init(JFinal.java:67)
at com.jfinal.core.JFinalFilter.init(JFinalFilter.java:49)
at org.eclipse.jetty.servlet.FilterHolder.doStart(FilterHolder.java:119)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:724)
at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:265)
at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1250)
at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:706)
at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:492)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
at org.eclipse.jetty.server.Server.doStart(Server.java:277)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
at com.jfinal.server.JettyServer.doStart(JettyServer.java:122)
at com.jfinal.server.JettyServer.start(JettyServer.java:65)
at com.jfinal.core.JFinal.start(JFinal.java:154)
at RunConfig.main(RunConfig.java:57)


可是我已经添加了freemarker-2.3.20.jar文件   请问到底什么原因导致的

加载中
返回顶部
顶部