有关jasperreports报错的问题java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRException

有关jasperreport开发的问题,单元测试的时候,已经通过,可以生成没有数据的pdf文件,但是整合到项目中的时候,却会报错
java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRException

下面是相关的代码

public class ATestJasperReport2 {


    public ATestJasperReport2() {

    }
    public static  void testReport(){   

        File jasperFileName = new File("f://Report/remoteReason.jasper");

        HashMap<String, Object> params = new HashMap<String, Object>();// 建立参数表
        params.put("reason_id", "原因编码"); // 设置参数值 - 暂时没用上           
        try {
            JasperPrint jasperPrint = JasperFillManager.fillReport(jasperFileName.getPath(), params , new JREmptyDataSource());
            JasperExportManager.exportReportToPdfFile(jasperPrint, "f://Report/test1.pdf");
        } catch (JRException e) {   
            System.out.println("异常");
            e.printStackTrace();
        }
    }

    public static void main(String arg[]){  
         testReport();
    }


}

下面是引用的jar包
图片说明

开发环境是 eclipse-INDIGO
java build path
图片说明

实在是搞不懂到底怎么回事,求大牛帮忙

4个回答

首先先感谢前面几位大佬提供的思路,没有他们,我还得耽误很久才能找到问题所在
虽然没能直接帮我解决问题,但是还是提供了正确的方向,感谢 矛十七,zoyation,
祗是辉哥哥 的帮助
下面是我解决这个问题的具体方法
1 首先项目是使用java8开发的,但是我原来使用的jasperReport只支持java7,所以重新找了一下lib包
地址如下https://download.csdn.net/download/luo381821/10613230(有几个包不全)
2 再项目中,配置引用的jar包 是在MANIFEST.MF进行的,而java build path 只是debug中使用,
在MANIFEST.MF中的Bundle-ClassPath: ., 里 添加使用的jar包,

再次运行的时候就成功了

Bundle-ClassPath: .,
 lib/druid-1.0.9.jar,
 lib/log4j-1.2.17.jar,
 lib/mysql-connector-java-5.1.35-bin.jar,
 lib/junit-4.10.jar,
 lib/xSocket-2.8.15.jar,
 lib/poi-3.12-20150511.jar,
 lib/lib-report-jdk1.8/commons-beanutils-1.9.3.jar,
 lib/lib-report-jdk1.8/commons-collections-3.2.2.jar,
 lib/lib-report-jdk1.8/commons-digester-2.1.jar,
 lib/lib-report-jdk1.8/commons-logging-1.1.1.jar,
 lib/lib-report-jdk1.8/groovy-all-2.4.5.jar,
 lib/lib-report-jdk1.8/itext-2.1.7.js6.jar,
 lib/lib-report-jdk1.8/iTextAsian.jar,
 lib/lib-report-jdk1.8/jasperreports-6.7.0.jar,
 lib/lib-report-jdk1.8/jasperreports-functions-6.7.0.jar,
 lib/lib-report-jdk1.8/jcommon-1.0.23.jar,
 lib/lib-report-jdk1.8/jfreechart-1.0.12.jar,
 lib/lib-report-jdk1.8/joda-time-2.1.jar,
 lib/lib-report-jdk1.8/poi-3.15.jar,
 lib/lib-report-jdk1.8/songti.jar
Export-Package: com.alibaba.druid,

这种情况一般是没有加载到jar包,你是放到生产上吗?

weixin_38782703
weixin_38782703 生产上是啥意思啊。。我把这些jar包都加到java build path 里了
大约一年之前 回复

图破了
1.可能是jar包冲突了,报表相关jar包版本不匹配不一致
2.可能开发运行环境配置不正确
3.缺少jar包

weixin_38782703
weixin_38782703 嗯嗯好的,我再试试
大约一年之前 回复
yangxingzou
zoyation 回复weixin_38782703: 最好都放到lib下
大约一年之前 回复
yangxingzou
zoyation 回复weixin_38782703: 检查下运行时编译后的目录,lib下有jar包吗?
大约一年之前 回复
weixin_38782703
weixin_38782703 我更新了一下,麻烦您再帮忙看一下。。
大约一年之前 回复

配置项不正确没有加载到这个jar包,也有可能是jar包版本不一致或者版本冲突,
看下引用的jar包含这个类似的net/sf/jasperreports/engine/JRException,这个意思就是这个jar里面的某个类没有加载到

weixin_38782703
weixin_38782703 回复祗是辉哥哥: 嗷嗷 好的,我再试试
大约一年之前 回复
weixin_42456466
祗是辉哥哥 回复weixin_38782703: 你之前单元测试不是好的嘛,这种情况可以排除了。也可以试试项目重新clean build
大约一年之前 回复
weixin_38782703
weixin_38782703 嗯嗯,这种情况有没有可能是 jasperreports-5.6.0.jar 这个jar包本身有问题啊。。
大约一年之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
有关jasperreports的问题 java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRException
有关jasperreport开发的问题,单元测试的时候,已经通过,可以生成没有数据源的pdf文件,但是整合到项目中的时候,却会报错 java.lang.NoClassDefFoundError: net/sf/jasperreports/engine/JRException 下面是相关的代码 ``` public class ATestJasperReport2 { public ATestJasperReport2() { } public void testReport(){ File jasperFileName = new File("f://Report/remoteReason.jasper"); HashMap<String, Object> params = new HashMap<String, Object>();// 建立参数表 params.put("reason_id", "原因编码"); // 设置参数值 - 暂时没用上 try { JasperPrint jasperPrint = JasperFillManager.fillReport(jasperFileName.getPath(), params , new JREmptyDataSource()); JasperExportManager.exportReportToPdfFile(jasperPrint, "f://Report/test1.pdf"); } catch (JRException e) { System.out.println("异常"); e.printStackTrace(); } } public static void main(String arg[]){ File jasperFileName = new File("f://Report/remoteReason.jasper"); HashMap<String, Object> params = new HashMap<String, Object>();// 建立参数表 params.put("reason_id", "原因编码"); // 设置参数值 - 暂时没用上 try { JasperPrint jasperPrint = JasperFillManager.fillReport(jasperFileName.getPath(), params , new JREmptyDataSource()); JasperExportManager.exportReportToPdfFile(jasperPrint, "f://Report/test1.pdf"); } catch (JRException e) { System.out.println("异常"); e.printStackTrace(); } } ``` 下面是引用的jar包 ![图片说明](https://img-ask.csdn.net/upload/201902/19/1550565146_571243.png) 开发环境是 eclipse-INDIGO 实在是搞不懂到底怎么回事
jasperreports-5.5.部署在linux上
Caused by: java.lang.NoClassDefFoundError: Could not initialize class net.sf.jasperreports.engine.util.JRStyledTextParser at net.sf.jasperreports.engine.fill.JRBaseFiller.<init>(JRBaseFiller.java:123) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:88) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:103) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:61) at net.sf.jasperreports.engine.fill.JRFiller.createFiller(JRFiller.java:179) at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:108) at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:653) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:969) ireport部署下linux下出现上述错误,版本jasperreports-5.5.1 搞了几天没解决。有没有大神知道的。指点一下。 谢谢 !
ireport java.lang.NullPointerException
java.lang.NullPointerException at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillGroupFooters(JRVerticalFiller.java:793) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportEnd(JRVerticalFiller.java:298) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:134) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:938) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:860) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:84) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:624) at org.apache.struts2.views.jasperreports.JasperReportsResult.doExecute(JasperReportsResult.java:240) at org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:178) at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:348) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:253) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:221) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:150) at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:48) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:123) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:184) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:105) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:83) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:207) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:74) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:127) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:107) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:206) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:115) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:143) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:121) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:170) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:123) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:176) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at cn.edu.zju.sgr.webapp.interceptor.LogInterseptor.intercept(LogInterseptor.java:13) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224) at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:223) at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221) at org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:50) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:504) at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:422) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1115) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378) at org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109) at org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.providers.anonymous.AnonymousProcessingFilter.doFilterHttp(AnonymousProcessingFilter.java:105) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.rememberme.RememberMeProcessingFilter.doFilterHttp(RememberMeProcessingFilter.java:116) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.basicauth.BasicProcessingFilter.doFilterHttp(BasicProcessingFilter.java:174) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:277) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.ui.logout.LogoutFilter.doFilterHttp(LogoutFilter.java:89) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) at org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1115) at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1115) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:361) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:533) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:207) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:403) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:522) 哪位牛人帮忙解决 定加分!!!!!!!!!!!!!!!!!!!!!!!!!!!!着急着急着
Ireport+struts2+javabean数据源解决子报表问题
Ireport+struts2+javabean做报表,用javabean做数据源报错,报错信息: net.sf.jasperreports.engine.JRException: Error retrieving field value from bean : deduTaxAccu at net.sf.jasperreports.engine.data.JRAbstractBeanDataSource.getBeanProperty(JRAbstractBeanDataSource.java:123) at net.sf.jasperreports.engine.data.JRAbstractBeanDataSource.getFieldValue(JRAbstractBeanDataSource.java:96) at net.sf.jasperreports.engine.data.JRBeanCollectionDataSource.getFieldValue(JRBeanCollectionDataSource.java:100) at net.sf.jasperreports.engine.fill.JRFillDataset.setOldValues(JRFillDataset.java:1331) at net.sf.jasperreports.engine.fill.JRFillDataset.next(JRFillDataset.java:1232) at net.sf.jasperreports.engine.fill.JRFillDataset.next(JRFillDataset.java:1208) at net.sf.jasperreports.engine.fill.JRBaseFiller.next(JRBaseFiller.java:1577) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:149) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:932) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:864) at net.sf.jasperreports.engine.fill.JRFillSubreport.fillSubreport(JRFillSubreport.java:655) at net.sf.jasperreports.engine.fill.JRSubreportRunnable.run(JRSubreportRunnable.java:59) at net.sf.jasperreports.engine.fill.AbstractThreadSubreportRunner.run(AbstractThreadSubreportRunner.java:203) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) Caused by: java.lang.NoSuchMethodException: Unknown property 'deduTaxAccu' on class 'class java.math.BigDecimal' at org.apache.commons.beanutils.PropertyUtilsBean.getSimpleProperty(PropertyUtilsBean.java:1322) at org.apache.commons.beanutils.PropertyUtilsBean.getNestedProperty(PropertyUtilsBean.java:770) at org.apache.commons.beanutils.PropertyUtilsBean.getProperty(PropertyUtilsBean.java:846) at org.apache.commons.beanutils.PropertyUtils.getProperty(PropertyUtils.java:426) at net.sf.jasperreports.engine.data.JRAbstractBeanDataSource.getBeanProperty(JRAbstractBeanDataSource.java:111) ... 15 more 求大神解答!!!!
JasperReports Subreport 表生成时赋值问题
在给对应report模板赋值的时候在上级map 中不是应该添加对应subreport expression 作为key对应的子报表的jasper JasperReport report3 = (JasperReport) JRLoader.loadObject(reportFile3); //子报表; m.put("$P{SUBREPORT_DIR}+PRN29Report_subreport3.jasper",report3); net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression : Source text : $P{SUBREPORT_DIR} + "PRN29Report_subreport3.jasper" at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:203) at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:591) at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:559) at net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:966) at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateReport(JRFillSubreport.java:295) at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateSubreport(JRFillSubreport.java:361) at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluate(JRFillSubreport.java:286) at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:259) at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:459) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:2044) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:778) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:288) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:151) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:909) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:841) at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:88) at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:653) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:969) 就报了如上错误 求大大帮忙解决一下
ssh+jasperreports做一个pdf预览功能报错,求助
javax.servlet.ServletException: Filter execution threw an exception root cause java.lang.NoSuchMethodError: net.sf.jasperreports.engine.util.JRLoader.loadObject(Ljava/lang/String;)Ljava/lang/Object; org.apache.struts2.views.jasperreports.JasperReportsResult.doExecute(JasperReportsResult.java:324) org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:186) com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:362) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:266)
ireport 编辑时报错。。。。。。。
Errors compiling .\MZSF.jasper! it.businesslogic.ireport.ReportClassLoader@4bbab7 net.sf.jasperreports.engine.JRException: Report design not valid : 1.Query parameter not found : depart_code at net.sf.jasperreports.engine.design.JRAbstractCompiler.verifyDesign(JRAbstractCompiler.java:267) at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(JRAbstractCompiler.java:144) at net.sf.jasperreports.engine.design.JRDefaultCompiler.compileReport(JRDefaultCompiler.java:131) at net.sf.jasperreports.engine.JasperCompileManager.compileReportToFile(JasperCompileManager.java:127) at net.sf.jasperreports.engine.JasperCompileManager.compileReportToFile(JasperCompileManager.java:109) at it.businesslogic.ireport.IReportCompiler.run(IReportCompiler.java:469) at java.lang.Thread.run(Thread.java:619)
jasperReport+iReport生成一个jasper文件后,用java程序调用该文件,报错误
java.lang.ClassNotFoundException: org.codehaus.groovy.runtime.callsite.CallSiteArray at java.lang.ClassLoader.findClass(ClassLoader.java:531) at java.lang.ClassLoader.loadClass(ClassLoader.java:425) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) at report2_1452134247794_802380.$createCallSiteArray(calculator_report2_1452134247794_802380) at report2_1452134247794_802380.$getCallSiteArray(calculator_report2_1452134247794_802380) at report2_1452134247794_802380.__$swapInit(calculator_report2_1452134247794_802380) at report2_1452134247794_802380.<clinit>(calculator_report2_1452134247794_802380) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:526) at java.lang.Class.newInstance(Class.java:374) at net.sf.jasperreports.engine.design.JRAbstractJavaCompiler.loadEvaluator(JRAbstractJavaCompiler.java:112) at net.sf.jasperreports.engine.design.JRAbstractCompiler.loadEvaluator(JRAbstractCompiler.java:340) at net.sf.jasperreports.engine.JasperCompileManager.getEvaluator(JasperCompileManager.java:378) at net.sf.jasperreports.engine.fill.JRFillDataset.createCalculator(JRFillDataset.java:462) at net.sf.jasperreports.engine.fill.JRBaseFiller.<init>(JRBaseFiller.java:405) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:89) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:104) at net.sf.jasperreports.engine.fill.JRVerticalFiller.<init>(JRVerticalFiller.java:62) at net.sf.jasperreports.engine.fill.JRFiller.createFiller(JRFiller.java:179) at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:108) at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:584) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:930) at com.yk.riantcb.controller.Controller_zzy.hell(Controller_zzy.java:152) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.springframework.web.bind.annotation.support.HandlerMethodInvoker.invokeHandlerMethod(HandlerMethodInvoker.java:176) at org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.invokeHandlerMethod(AnnotationMethodHandlerAdapter.java:440) at org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.handle(AnnotationMethodHandlerAdapter.java:428) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:827) at javax.servlet.http.HttpServlet.service(HttpServlet.java:621) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:233) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449) at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365) at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:383) at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:259) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1002) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:585) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:310) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:744)
关于ireport报错的问题,哪位比较熟悉的请教一下
错误如下:谢谢 [code="java"] Error filling print... Error evaluating expression :      Source text : 第一次查询 net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression :      Source text : 第一次查询      at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:195)      at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:589)      at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:557)      at net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:929)      at net.sf.jasperreports.engine.fill.JRFillTextField.evaluateText(JRFillTextField.java:383)      at net.sf.jasperreports.engine.fill.JRFillTextField.evaluate(JRFillTextField.java:368)      at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:258)      at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:499)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillTitle(JRVerticalFiller.java:326)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:262)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:128)      at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:946)      at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:845)      at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:58)      at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:417)      at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:247)      at com.jaspersoft.ireport.designer.compiler.IReportCompiler.run(IReportCompiler.java:877)      at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:572)      at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:997)  Caused by: groovy.lang.MissingPropertyException: No such property: 第一次查询 for class: temple_1293355820828_958276      at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:49)      at org.codehaus.groovy.runtime.callsite.GetEffectivePogoPropertySite.getProperty(GetEffectivePogoPropertySite.java:86)      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGroovyObjectGetProperty(AbstractCallSite.java:239)      at temple_1293355820828_958276.evaluate(calculator_temple_1293355820828_958276:173)      at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:182)      ... 18 more  Print not filled. Try to use an EmptyDataSource... [/code]
JasperReport问题~
JasperCompileManager.compileReportToFile(application.getRealPath("report.jrxml")); 报错 [code="java"]net.sf.jasperreports.engine.JRException: org.xml.sax.SAXException: http://java.sun.com/xml/jaxp/properties/schemaSource at net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:243) at net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:226) at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:214) at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:168) at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:152) at vebeg.werbung.JRCreateBericht.createBericht(JRCreateBericht.java:32) at vebeg.werbung.TestJRCreateBericht.testCreateBericht(TestJRCreateBericht.java:15) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99) at org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81) at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34) at org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75) at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45) at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71) at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35) at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42) at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34) at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:45) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196) Caused by: org.xml.sax.SAXException: http://java.sun.com/xml/jaxp/properties/schemaSource at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1197) at org.apache.commons.digester.Digester.parse(Digester.java:1745) at net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:239) ... 26 more [/code]
java 打印报表问题(编译报表时出错)
我设计好了报表放在sampleReportFile + ".jrxml",然后加载进来,再编译。如下代码 JasperDesign design = JRXmlLoader.load(sampleReportFile + ".jrxml"); //编译 JasperReport report = new JasperCompileManager().compileReport(design);//这句有异常 这两行代码放的一个单独的类中的main里能正常运行。 但是放到我的项目中就报异常,无法编译,抛出异常如下(myReport_1216356285140_165076.class这个文件是它自动创建的怎么找不到?但在单独类中的main中为什么行?)。 java.io.FileNotFoundException: D:\other-workspace\TestReport\myReport_1216356285140_165076.class (系统找不到指定的文件。) at java.io.FileInputStream.open(Native Method) at java.io.FileInputStream.<init>(Unknown Source) at net.sf.jasperreports.engine.util.JRLoader.loadBytes(Unknown Source) at net.sf.jasperreports.engine.design.JRAbstractClassCompiler.compileUnits(Unknown Source) at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(Unknown Source) at net.sf.jasperreports.engine.design.JRDefaultCompiler.compileReport(Unknown Source) at net.sf.jasperreports.engine.JasperCompileManager.compileReportToFile(Unknown Source) at net.sf.jasperreports.engine.JasperCompileManager.compileReportToFile(Unknown Source) at com.dsrcom.ecq.client.report.view.ReportColumnSet.printReport(ReportColumnSet.java:638) at com.dsrcom.ecq.client.report.view.ReportColumnSet$5.mouseUp(ReportColumnSet.java:417) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:137) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1914) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177) 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 org.eclipse.core.launcher.Main.invokeFramework(Main.java:336) at org.eclipse.core.launcher.Main.basicRun(Main.java:280) at org.eclipse.core.launcher.Main.run(Main.java:977) at org.eclipse.core.launcher.Main.main(Main.java:952) 这个是怎么解决的呀!大神帮忙!
ireport导出excel包含饼图就会异常
严重: Servlet.service() for servlet [springmvc] in context with path [/springmvc] threw exception [Request processing failed; nested exception is net.sf.jasperreports.engine.JRException: The cell cannot be added.] with root cause java.lang.NoSuchMethodError: org.apache.poi.hssf.usermodel.HSSFClientAnchor.setAnchorType(I)V at net.sf.jasperreports.engine.export.JRXlsExporter.exportImage(JRXlsExporter.java:1504)
IReport制作子表发生的错误
主表jrxml是: <?xml version="1.0" encoding="UTF-8"?> <jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="annual_energy_report" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="23681347-e35c-4c2b-baef-61e923a79360"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <property name="net.sf.jasperreports.export.xls.white.page.background" value="false"/> <property name="net.sf.jasperreports.export.xls.detect.cell.type" value="true"/> <property name="net.sf.jasperreports.export.xls.remove.empty.space.between.rows" value="true"/> <property name="net.sf.jasperreports.export.xls.freeze.row" value="2"/> <parameter name="SUBREPORT_DIR" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA["C:\\Users\\xp\\Desktop\\ireport\\sjt\\"]]></defaultValueExpression> </parameter> <queryString> <![CDATA[]]> </queryString> <field name="annualBuild" class="java.util.List"> <fieldDescription><![CDATA[annualBuild]]></fieldDescription> </field> <field name="annualBuildDetail" class="java.util.List"> <fieldDescription><![CDATA[annualBuildDetail]]></fieldDescription> </field> <field name="annualItem" class="java.util.List"> <fieldDescription><![CDATA[annualItem]]></fieldDescription> </field> <field name="annualUnit" class="java.util.List"> <fieldDescription><![CDATA[annualUnit]]></fieldDescription> </field> <field name="reportName" class="java.lang.String"> <fieldDescription><![CDATA[reportName]]></fieldDescription> </field> <field name="class" class="java.lang.Class"> <fieldDescription><![CDATA[class]]></fieldDescription> </field> <background> <band splitType="Prevent"/> </background> <title> <band height="37" splitType="Stretch"> <staticText> <reportElement uuid="49fdd926-8d95-4ee7-839a-b690e5676750" x="0" y="0" width="555" height="30"/> <textElement textAlignment="Center"> <font size="20" isBold="true"/> </textElement> <text><![CDATA[2013年度全校能耗统计报表]]></text> </staticText> </band> </title> <pageHeader> <band height="12" splitType="Stretch"/> </pageHeader> <columnHeader> <band height="10" splitType="Stretch"/> </columnHeader> <detail> <band height="681" splitType="Stretch"> <subreport> <reportElement uuid="9caa7184-12c0-4af9-a849-99293b17a88a" x="0" y="39" width="299" height="103"/> <dataSourceExpression><![CDATA[net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualBuild})]]></dataSourceExpression> <subreportExpression><![CDATA[$P{SUBREPORT_DIR} + "annual_energy_report_building.jasper"]]></subreportExpression> </subreport> <subreport> <reportElement uuid="811885e4-1548-40b0-a18c-92dc44ab1908" x="0" y="197" width="299" height="100"/> <dataSourceExpression><![CDATA[net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualUnit})]]></dataSourceExpression> <subreportExpression><![CDATA[$P{SUBREPORT_DIR} + "annual_energy_report_unit.jasper"]]></subreportExpression> </subreport> <subreport> <reportElement uuid="5551d080-0c07-45ce-ac04-ec47eaa8a01f" x="0" y="372" width="299" height="100"/> <dataSourceExpression><![CDATA[net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualItem})]]></dataSourceExpression> <subreportExpression><![CDATA[$P{SUBREPORT_DIR} + "annual_energy_report_item.jasper"]]></subreportExpression> </subreport> <subreport> <reportElement uuid="b2304c61-6a20-47ad-83aa-c17d4058dc89" x="0" y="552" width="299" height="100"/> <dataSourceExpression><![CDATA[net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualBuildDetail})]]></dataSourceExpression> <subreportExpression><![CDATA[$P{SUBREPORT_DIR} + "annual_energy_report_buildDetail.jasper"]]></subreportExpression> </subreport> </band> </detail> <columnFooter> <band height="45" splitType="Stretch"/> </columnFooter> <pageFooter> <band height="54" splitType="Stretch"/> </pageFooter> <summary> <band height="42" splitType="Stretch"/> </summary> </jasperReport> 编译通过,但是阅览时报错,如下: Error filling print... Error evaluating expression :      Source text : net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualBuild}) Setting up the file resolver...  net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression :      Source text : net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{annualBuild})      at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:203)      at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:591)      at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:559)      at net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:966)      at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateSubreport(JRFillSubreport.java:392)      at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluate(JRFillSubreport.java:294)      at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:259)      at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:455)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:2044)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:778)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:288)      at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:151)      at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:909)      at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:841)      at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:88)      at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:653)      at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:569)      at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:915)      at com.jaspersoft.ireport.designer.compiler.IReportCompiler.run(IReportCompiler.java:928)      at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:572)      at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:997)  Caused by: groovy.lang.MissingPropertyException: No such property: net for class: annual_energy_report_1372136929372_105017      at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:50)      at org.codehaus.groovy.runtime.callsite.GetEffectivePogoPropertySite.getProperty(GetEffectivePogoPropertySite.java:86)      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGroovyObjectGetProperty(AbstractCallSite.java:231)      at annual_energy_report_1372136929372_105017.evaluate(calculator_annual_energy_report_1372136929372_105017:173)      at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:190)      ... 20 more  Print not filled. Try to use an EmptyDataSource...
Error trying to export to file
net.sf.jasperreports.engine.JRException: Error trying to export to file : TransformXMLtoHTML\PDFReports\TransportLabel_3879017041.pdf at net.sf.jasperreports.engine.export.JRPdfExporter.exportReport(JRPdfExporter.java:355) at net.sf.jasperreports.engine.JasperExportManager.exportReportToPdfFile(JasperExportManager.java:126) at com.dhl.sop.label.LabelReportController.generateSOPLabel(LabelReportController.java:461) at com.dhl.sop.label.LabelReportHandler.generate(LabelReportHandler.java:82) at com.dhl.sop.label.LabelReportHandler.main(LabelReportHandler.java:68) Caused by: java.io.FileNotFoundException: TransformXMLtoHTML\PDFReports\TransportLabel_3879017041.pdf (系统找不到指定的路径。) at java.io.FileOutputStream.open(Native Method) at java.io.FileOutputStream.<init>(Unknown Source) at java.io.FileOutputStream.<init>(Unknown Source) at net.sf.jasperreports.engine.export.JRPdfExporter.exportReport(JRPdfExporter.java:349) ... 4 more
jasperreports 打印pdf报错 急。。。。。。
HTTP Status 500 - -------------------------------------------------------------------------------- type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception javax.servlet.ServletException: Filter execution threw an exception root cause java.lang.NoSuchMethodError: com.opensymphony.xwork2.ActionContext.get(Ljava/lang/Object;)Ljava/lang/Object; org.apache.struts2.views.jasperreports.JasperReportsResult.doExecute(JasperReportsResult.java:199) org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:186) com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:361) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:265) com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:163) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:249) org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:122) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:148) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:93) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:235) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:89) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:128) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:104) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:267) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:126) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:138) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:148) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:164) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:128) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:176) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:52) org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:468) org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:395) note The full stack trace of the root cause is available in the Apache Tomcat/6.0.14 logs. -------------------------------------------------------------------------------- Apache Tomcat/6.0.14
iReport报表打开报错,不知道这是个什么错,从来没有遇到过!
Error loading the report template Message: net.sf.jasperreports.engine.JRException: org.xml.sax.SAXParseException: cvc-complex-type.3.2.2: Attribute 'isSummaryWithPageHeaderAndFooter' is not allowed to appear in element 'jasperReport'. Level: SEVERE Stack Trace: org.xml.sax.SAXParseException: cvc-complex-type.3.2.2: Attribute 'isSummaryWithPageHeaderAndFooter' is not allowed to appear in element 'jasperReport'. net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:239) net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:222) net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:210) com.jaspersoft.ireport.designer.JrxmlLoader.reloadJasperDesign(JrxmlLoader.java:87) com.jaspersoft.ireport.designer.JrxmlVisualView.run(JrxmlVisualView.java:505) org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:561) org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:986) cvc-complex-type.3.2.2: Attribute 'isSummaryWithPageHeaderAndFooter' is not allowed to appear in element 'jasperReport'. com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:195) com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:131) com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:384) com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:318) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(XMLSchemaValidator.java:423) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.reportSchemaError(XMLSchemaValidator.java:3188) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.processAttributes(XMLSchemaValidator.java:2665) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:2072) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:711) com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:400) com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl$NSContentDriver.scanRootElementHook(XMLNSDocumentScannerImpl.java:626) com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3104) com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:921) com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:647) com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140) com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:511) com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:808) com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737) com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:119) com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205) com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522) org.apache.commons.digester.Digester.parse(Digester.java:1647) net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:235) net.sf.jasperreports.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:222) net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:210) com.jaspersoft.ireport.designer.JrxmlLoader.reloadJasperDesign(JrxmlLoader.java:87) com.jaspersoft.ireport.designer.JrxmlVisualView.run(JrxmlVisualView.java:505) org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:561) org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:986) 不知道是个什么情况,前一个月还是好的,现在打开就这样了。
java生成PDF的时候报了 如下异常 怎么回事呢
用的是struts2+ibatis2.x+spring2.x 报了 如下异常 : java.lang.NoSuchMethodError: com.lowagie.text.pdf.PdfWriter.setRgbTransparencyBlending(Z)V at net.sf.jasperreports.engine.export.JRPdfExporter.exportReportToStream(JRPdfExporter.java:455) at net.sf.jasperreports.engine.export.JRPdfExporter.exportReport(JRPdfExporter.java:333) at org.apache.struts2.views.jasperreports.JasperReportsResult.exportReportToBytes(JasperReportsResult.java:456) at org.apache.struts2.views.jasperreports.JasperReportsResult.doExecute(JasperReportsResult.java:365) at org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:186) at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:361) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:265) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:163) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:249) at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:122) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:195) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:148) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:93) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:235) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:89) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:128) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:104) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:267) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:126) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:138) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:87) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:148) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:164) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:128) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:176) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:236) at org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:52) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:468) at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:395) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:39) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCleanUp.java:102) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595)
在java web工程中·,利用ireport生成的jasper文件,导出pdf文件
我已经用ireport工具生成了jasper文件,并且利用ireport已经可以成功预览并生成pdf文件,但是现在需要在java web工程中,利用jasper文件生成相应的pdf文件,自己测视了好久,在网上也搜了好久,没有找到解决办法,现在把相应代码及错误贴出来,希望会做的朋友帮忙改正一下! 主要的servlet文件,在web.xml中都已将其配置好了 import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.PrintWriter; import java.sql.Connection; import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.File; import java.sql.Connection; import java.sql.SQLException; import java.util.HashMap; import java.util.Map; import util.JDBCConnection; import net.sf.jasperreports.engine.JRException; import net.sf.jasperreports.engine.JRExporterParameter; import net.sf.jasperreports.engine.JasperFillManager; import net.sf.jasperreports.engine.JasperPrint; import net.sf.jasperreports.engine.JasperReport; import net.sf.jasperreports.engine.JasperRunManager; import net.sf.jasperreports.engine.export.JRHtmlExporter; import net.sf.jasperreports.engine.export.JRHtmlExporterParameter; import net.sf.jasperreports.engine.export.JRPdfExporter; import net.sf.jasperreports.engine.export.JRXlsExporter; import net.sf.jasperreports.engine.export.JRXlsExporterParameter; import net.sf.jasperreports.engine.util.JRLoader; public class JRHTMLServlet extends HttpServlet { private Connection conn = JDBCConnection.getConnection(); //这个是连接mysql数据库 public JRHTMLServlet() { super(); } public void destroy() { super.destroy(); // Just puts "destroy" string in log // Put your code here } public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { String type = request.getParameter("type"); try { ServletContext servletContext = this.getServletContext(); File reportFile = new File(servletContext.getRealPath("/")+"/WEB-INF/report/Untitled_report_1.jasper"); Map parameters = new HashMap(); if("pdf".equals(type)){ byte[] bytes = JasperRunManager.runReportToPdf(reportFile.getPath(), parameters, conn); response.setContentType("application/pdf"); response.addHeader("Content-Disposition", "attachment; filename=report.pdf"); response.setContentLength(bytes.length); ServletOutputStream ouputStream = response.getOutputStream(); ouputStream.write(bytes, 0, bytes.length); ouputStream.flush(); ouputStream.close(); } else if ("excel".equals(type)){ JRXlsExporter exporter = new JRXlsExporter(); ByteArrayOutputStream oStream = new ByteArrayOutputStream(); JasperPrint jasperPrint = JasperFillManager.fillReport(reportFile.getPath(), parameters, conn); exporter.setParameter(JRExporterParameter.JASPER_PRINT, jasperPrint); exporter.setParameter(JRExporterParameter.OUTPUT_STREAM, oStream); exporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); exporter.setParameter(JRXlsExporterParameter.IS_ONE_PAGE_PER_SHEET, Boolean.FALSE); exporter.setParameter(JRXlsExporterParameter.IS_WHITE_PAGE_BACKGROUND, Boolean.FALSE); exporter.exportReport(); byte[] bytes = oStream.toByteArray(); response.setContentType("application/vnd.ms-excel"); response.addHeader("Content-Disposition", "attachment; filename=report.xls"); response.setContentLength(bytes.length); ServletOutputStream ouputStream = response.getOutputStream(); ouputStream.write(bytes, 0, bytes.length); ouputStream.flush(); ouputStream.close(); } else { JRHtmlExporter exporter = new JRHtmlExporter(); ByteArrayOutputStream oStream = new ByteArrayOutputStream(); JasperPrint jasperPrint = JasperFillManager.fillReport(reportFile.getPath(), parameters, conn); exporter.setParameter(JRHtmlExporterParameter.IS_USING_IMAGES_TO_ALIGN, Boolean.FALSE); exporter.setParameter(JRHtmlExporterParameter.JASPER_PRINT, jasperPrint); exporter.setParameter(JRHtmlExporterParameter.CHARACTER_ENCODING, "utf-8"); exporter.setParameter(JRHtmlExporterParameter.OUTPUT_STREAM, oStream); exporter.exportReport(); byte[] bytes = oStream.toByteArray(); response.setContentType("text/html"); response.setContentLength(bytes.length); response.setCharacterEncoding("utf-8"); ServletOutputStream ouputStream = response.getOutputStream(); ouputStream.write(bytes, 0, bytes.length); ouputStream.flush(); ouputStream.close(); } } catch (JRException jre) { System.out.println("JRException:" + jre.getMessage()); } catch (Exception e) { System.out.println("Exception:" + e.getMessage()); } finally{ try { conn.close(); } catch (SQLException ex) { // TODO Auto-generated catch block ex.printStackTrace(); } } } public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { this.doGet(request, response); } } 在jsp文件中的主要代码: <a href="JRHTMLServlet?type=pdf">Servlet中生成pdf</a> <a href="JRHTMLServlet?type=excel">Servlet中生成excel</a> <a href="JRHTMLServlet?type=html">Servlet中生成html</a> 然后编译都没有问题,在执行时,如果点击了“Servlet中生成pdf”超链接,就会提示错误: JRException:Error evaluating expression : Source text : new java.lang.Integer(1) 若点击“Servlet中生成excel”超链接,就会提示错误: 严重: Servlet.service() for servlet JRHTMLServlet threw exception java.lang.ClassNotFoundException: org.apache.poi.ss.usermodel.Sheet 若点击“Servlet中生成html”超链接,就会提示错误: JRException:Error preparing statement for executing the report query : SELECT customer.`ID` AS customer_ID, customer.`USERNAME` AS customer_USERNAME, customer.`PASSWORD` AS customer_PASSWORD, customer.`REALNAME` AS customer_REALNAME, customer.`ADDRESS` AS customer_ADDRESS, customer.`MOBILE` AS customer_MOBILE, customer.`IDCARD_ID` AS customer_IDCARD_ID FROM `customer` customer 以上三种都试了,执行时,页面都可以跳转,但是跳转之后,都没有显示,直接出错了,我尝试了好久好久,确实不知道是什么问题,还请各位帮忙看看啊,在这里先谢谢你们啦 附:数据库的连接: String url = "jdbc:mysql://localhost/test"; String userName = "root"; String password = "123456"; Class.forName("com.mysql.jdbc.Driver"); Connection connection = DriverManager.getConnection(url, userName,password); 数据库表里面有中文,应该没有影响,现在只要求可以在web工程中导出pdf就可以了
jasperreports-3.6.0问题
大家 好想问个问题 ,之前 在用 jasperreport 2.* 做报表,最近 从官方网站 看到 已经升级到了 3.6 , 想问问 ,版本升级 后 新功能 以及 他们的区别 等内容? 谢谢
对计算机专业来说学历真的重要吗?
我本科学校是渣渣二本,研究生学校是985,现在毕业五年,校招笔试、面试,社招面试参加了两年了,就我个人的经历来说下这个问题。 这篇文章很长,但绝对是精华,相信我,读完以后,你会知道学历不好的解决方案,记得帮我点赞哦。 先说结论,无论赞不赞同,它本质就是这样:对于技术类工作而言,学历五年以内非常重要,但有办法弥补。五年以后,不重要。 目录: 张雪峰讲述的事实 我看到的事实 为什么会这样 ...
Java学习的正确打开方式
在博主认为,对于入门级学习java的最佳学习方法莫过于视频+博客+书籍+总结,前三者博主将淋漓尽致地挥毫于这篇博客文章中,至于总结在于个人,实际上越到后面你会发现学习的最好方式就是阅读参考官方文档其次就是国内的书籍,博客次之,这又是一个层次了,这里暂时不提后面再谈。博主将为各位入门java保驾护航,各位只管冲鸭!!!上天是公平的,只要不辜负时间,时间自然不会辜负你。 何谓学习?博主所理解的学习,它是一个过程,是一个不断累积、不断沉淀、不断总结、善于传达自己的个人见解以及乐于分享的过程。
程序员必须掌握的核心算法有哪些?
由于我之前一直强调数据结构以及算法学习的重要性,所以就有一些读者经常问我,数据结构与算法应该要学习到哪个程度呢?,说实话,这个问题我不知道要怎么回答你,主要取决于你想学习到哪些程度,不过针对这个问题,我稍微总结一下我学过的算法知识点,以及我觉得值得学习的算法。这些算法与数据结构的学习大多数是零散的,并没有一本把他们全部覆盖的书籍。下面是我觉得值得学习的一些算法以及数据结构,当然,我也会整理一些看过...
大学四年自学走来,这些私藏的实用工具/学习网站我贡献出来了
大学四年,看课本是不可能一直看课本的了,对于学习,特别是自学,善于搜索网上的一些资源来辅助,还是非常有必要的,下面我就把这几年私藏的各种资源,网站贡献出来给你们。主要有:电子书搜索、实用工具、在线视频学习网站、非视频学习网站、软件下载、面试/求职必备网站。 注意:文中提到的所有资源,文末我都给你整理好了,你们只管拿去,如果觉得不错,转发、分享就是最大的支持了。 一、电子书搜索 对于大部分程序员...
小白学 Python 爬虫(25):爬取股票信息
人生苦短,我用 Python 前文传送门: 小白学 Python 爬虫(1):开篇 小白学 Python 爬虫(2):前置准备(一)基本类库的安装 小白学 Python 爬虫(3):前置准备(二)Linux基础入门 小白学 Python 爬虫(4):前置准备(三)Docker基础入门 小白学 Python 爬虫(5):前置准备(四)数据库基础 小白学 Python 爬虫(6):前置准备(...
小知识:浅谈二维码的生成和识别原理
目录 前言 条形码 静态二维码 二进制生成图形码 二维码的定位 前言 不知不觉中,我们的生活到处充满了二维码。登录账户需要二维码;加好友需要二维码;共享单车需要二维码;商品包装上也有二维码;甚至连楼下卖水果的阿姨手里都拿张二维码收款。那么,有没有想过这个二维码到底是什么东西呢?那么这个二维码的图案会不会多到不小心重合了呢? 条形码 在二维码出现之前,大行其道的...
[享学Jackson] 一、初识Jackson -- 世界上最好的JSON库
Jackson是一个简单的、功能强大的、基于Java的**应用库**。它可以很方便完成**Java对象**和**json对象(xml文档or其它格式)**进行互转。Jackson社区相对比较活跃,更新速度也比较快。Jackson库有如下几大特性: - 高性能,稳定:低内存占用,对大/小JSON串,大/小对象的解析表现均很优秀 - 流行度高:是很多流行框架的默认实现 - 容易使用:提供高层次的API,极大简化了日常使用 - 无需自己手动创建映射:内置了绝大部分序列化时和Java类型的映射关系 - 干净的JSO
卸载 x 雷某度!GitHub 标星 1.5w+,从此我只用这款全能高速下载工具!
作者 | Rocky0429 来源 | Python空间 大家好,我是 Rocky0429,一个喜欢在网上收集各种资源的蒟蒻… 网上资源眼花缭乱,下载的方式也同样千奇百怪,比如 BT 下载,磁力链接,网盘资源等等等等,下个资源可真不容易,不一样的方式要用不同的下载软件,因此某比较有名的 x 雷和某度网盘成了我经常使用的工具。 作为一个没有钱的穷鬼,某度网盘几十 kb 的下载速度让我...
世界上最牛的网络设备,价格低廉,其貌不扬......
夜深人静,电视和电脑都已经关机休息,但是我还在默默工作,我安静地趴在你家中的某个地方,7*24小时不眠不休,任劳任怨,目的只有一个,能让你舒服地躺在床上,畅快地刷手机!没错,这就是我,...
《面试宝典》2019年springmvc面试高频题(java)
前言 2019即将过去,伴随我们即将迎来的又是新的一年,过完春节,马上又要迎来新的金三银四面试季。那么,作为程序猿的你,是否真的有所准备的呢,亦或是安于本职工作,继续做好手头上的事情。 当然,不论选择如何,假如你真的准备在之后的金三银四跳槽的话,那么作为一个Java工程师,就不可不看了。如何在几个月的时间里,快速的为即将到来的面试进行充分的准备呢? 1、什么是Spring MVC ?简单...
一名大专同学的四个问题
【前言】   收到一封来信,赶上各种事情拖了几日,利用今天要放下工作的时机,做个回复。   2020年到了,就以这一封信,作为开年标志吧。 【正文】   您好,我是一名现在有很多困惑的大二学生。有一些问题想要向您请教。   先说一下我的基本情况,高考失利,不想复读,来到广州一所大专读计算机应用技术专业。学校是偏艺术类的,计算机专业没有实验室更不用说工作室了。而且学校的学风也不好。但我很想在计算机领...
复习一周,京东+百度一面,不小心都拿了Offer
京东和百度一面都问了啥,面试官百般刁难,可惜我全会。
轻松搭建基于 SpringBoot + Vue 的 Web 商城应用
首先介绍下在本文出现的几个比较重要的概念: 函数计算(Function Compute): 函数计算是一个事件驱动的服务,通过函数计算,用户无需管理服务器等运行情况,只需编写代码并上传。函数计算准备计算资源,并以弹性伸缩的方式运行用户代码,而用户只需根据实际代码运行所消耗的资源进行付费。Fun: Fun 是一个用于支持 Serverless 应用部署的工具,能帮助您便捷地管理函数计算、API ...
Python+OpenCV实时图像处理
目录 1、导入库文件 2、设计GUI 3、调用摄像头 4、实时图像处理 4.1、阈值二值化 4.2、边缘检测 4.3、轮廓检测 4.4、高斯滤波 4.5、色彩转换 4.6、调节对比度 5、退出系统 初学OpenCV图像处理的小伙伴肯定对什么高斯函数、滤波处理、阈值二值化等特性非常头疼,这里给各位分享一个小项目,可通过摄像头实时动态查看各类图像处理的特点,也可对各位调参、测试...
2020年一线城市程序员工资大调查
人才需求 一线城市共发布岗位38115个,招聘120827人。 其中 beijing 22805 guangzhou 25081 shanghai 39614 shenzhen 33327 工资分布 2020年中国一线城市程序员的平均工资为16285元,工资中位数为14583元,其中95%的人的工资位于5000到20000元之间。 和往年数据比较: yea...
为什么猝死的都是程序员,基本上不见产品经理猝死呢?
相信大家时不时听到程序员猝死的消息,但是基本上听不到产品经理猝死的消息,这是为什么呢? 我们先百度搜一下:程序员猝死,出现将近700多万条搜索结果: 搜索一下:产品经理猝死,只有400万条的搜索结果,从搜索结果数量上来看,程序员猝死的搜索结果就比产品经理猝死的搜索结果高了一倍,而且从下图可以看到,首页里面的五条搜索结果,其实只有两条才是符合条件。 所以程序员猝死的概率真的比产品经理大,并不是错...
害怕面试被问HashMap?这一篇就搞定了!
声明:本文以jdk1.8为主! 搞定HashMap 作为一个Java从业者,面试的时候肯定会被问到过HashMap,因为对于HashMap来说,可以说是Java集合中的精髓了,如果你觉得自己对它掌握的还不够好,我想今天这篇文章会非常适合你,至少,看了今天这篇文章,以后不怕面试被问HashMap了 其实在我学习HashMap的过程中,我个人觉得HashMap还是挺复杂的,如果真的想把它搞得明明白...
毕业5年,我问遍了身边的大佬,总结了他们的学习方法
我问了身边10个大佬,总结了他们的学习方法,原来成功都是有迹可循的。
推荐10个堪称神器的学习网站
每天都会收到很多读者的私信,问我:“二哥,有什么推荐的学习网站吗?最近很浮躁,手头的一些网站都看烦了,想看看二哥这里有什么新鲜货。” 今天一早做了个恶梦,梦到被老板辞退了。虽然说在我们公司,只有我辞退老板的份,没有老板辞退我这一说,但是还是被吓得 4 点多都起来了。(主要是因为我掌握着公司所有的核心源码,哈哈哈) 既然 4 点多起来,就得好好利用起来。于是我就挑选了 10 个堪称神器的学习网站,推...
这些软件太强了,Windows必装!尤其程序员!
Windows可谓是大多数人的生产力工具,集娱乐办公于一体,虽然在程序员这个群体中都说苹果是信仰,但是大部分不都是从Windows过来的,而且现在依然有很多的程序员用Windows。 所以,今天我就把我私藏的Windows必装的软件分享给大家,如果有一个你没有用过甚至没有听过,那你就赚了????,这可都是提升你幸福感的高效率生产力工具哦! 走起!???? NO、1 ScreenToGif 屏幕,摄像头和白板...
(总结)阿里面试问了ArrayList,都问了啥?
我是真的没想到,面试官会这样问我ArrayList。
曾经优秀的人,怎么就突然不优秀了。
职场上有很多辛酸事,很多合伙人出局的故事,很多技术骨干被裁员的故事。说来模板都类似,曾经是名校毕业,曾经是优秀员工,曾经被领导表扬,曾经业绩突出,然而突然有一天,因为种种原因,被裁员了,...
大学四年因为知道了这32个网站,我成了别人眼中的大神!
依稀记得,毕业那天,我们导员发给我毕业证的时候对我说“你可是咱们系的风云人物啊”,哎呀,别提当时多开心啦????,嗯,我们导员是所有导员中最帅的一个,真的???? 不过,导员说的是实话,很多人都叫我大神的,为啥,因为我知道这32个网站啊,你说强不强????,这次是绝对的干货,看好啦,走起来! PS:每个网站都是学计算机混互联网必须知道的,真的牛杯,我就不过多介绍了,大家自行探索,觉得没用的,尽管留言吐槽吧???? 社...
2020年1月中国编程语言排行榜,python是2019增长最快编程语言
编程语言比例 排名 编程语言 最低工资 工资中位数 最低工资 最高工资 人头 人头百分比 1 rust 20713 17500 5042 46250 480 0.14% 2 typescript 18503 22500 6000 30000 1821 0.52% 3 lua 18150 17500 5250 35000 2956 0.84% 4 go 17989 16...
看完这篇HTTP,跟面试官扯皮就没问题了
我是一名程序员,我的主要编程语言是 Java,我更是一名 Web 开发人员,所以我必须要了解 HTTP,所以本篇文章就来带你从 HTTP 入门到进阶,看完让你有一种恍然大悟、醍醐灌顶的感觉。 最初在有网络之前,我们的电脑都是单机的,单机系统是孤立的,我还记得 05 年前那会儿家里有个电脑,想打电脑游戏还得两个人在一个电脑上玩儿,及其不方便。我就想为什么家里人不让上网,我的同学 xxx 家里有网,每...
史上最全的IDEA快捷键总结
现在Idea成了主流开发工具,这篇博客对其使用的快捷键做了总结,希望对大家的开发工作有所帮助。
阿里程序员写了一个新手都写不出的低级bug,被骂惨了。
这种新手都不会范的错,居然被一个工作好几年的小伙子写出来,差点被当场开除了。
谁是华为扫地僧?
是的,华为也有扫地僧!2020年2月11-12日,“养在深闺人不知”的华为2012实验室扫地僧们,将在华为开发者大会2020(Cloud)上,和大家见面。到时,你可以和扫地僧们,吃一个洋...
Idea 中最常用的10款插件(提高开发效率),一定要学会使用!
学习使用一些插件,可以提高开发效率。对于我们开发人员很有帮助。这篇博客介绍了开发中使用的插件。
AI 没让人类失业,搞 AI 的人先失业了
最近和几个 AI 领域的大佬闲聊 根据他们讲的消息和段子 改编出下面这个故事 如有雷同 都是巧合 1. 老王创业失败,被限制高消费 “这里写我跑路的消息实在太夸张了。” 王葱葱哼笑一下,把消息分享给群里。 阿杰也看了消息,笑了笑。在座几位也都笑了。 王葱葱是个有名的人物,21岁那年以全额奖学金进入 KMU 攻读人工智能博士,累计发表论文 40 余篇,个人技术博客更是成为深度学习领域内风向标。 ...
立即提问