zoukankan      html  css  js  c++  java
  • Caused by: java.lang.NoClassDefFoundError at com.jc.zm.ZmAlarmAction.analyDo(ZmAlarmAction.java:198)

       ZmPlanDayAction objPlanDay = new ZmPlanDayAction();
       objPlanDay.setDao(dao);
       objPlanDay.setServletRequest(req);
       objPlanDay.analy(prcsDate, itemId, "01", id, custId, "01", condId, condName,
        mayQues, contentId, contentName, measure, content, analy);

    运行时,执行到第一行时出现了下面的错误:

    Caused by: java.lang.NoClassDefFoundError at com.jc.zm.ZmAlarmAction.analyDo(ZmAlarmAction.java:198)

    检查发现,ZmPlanDayAction.class 文件存在,后仔细检查发现,原来这些文件在开始的时候就已经出错了,导致了class文件不能执行下去的情况。

    ZmPlanDayAction.java在开头时候的语句错误了。代码如下:

     private static Integer dayPlanFlowId = Integer.parseInt(BaseConfig.getValue("dayPlanFlowId"));
     private static Integer weekPlanFlowId = Integer.parseInt(BaseConfig.getValue("weekPlanFlowId"));
     private static Integer monthPlanFlowId = Integer.parseInt(BaseConfig.getValue("monthPlanFlowId"));
     private static Integer planSumFlowId = Integer.parseInt(BaseConfig.getValue("planSumFlowId"));

    最后一句代码中的 planSumFlowId 这个在配置文件(baseconfig.properties)中的名称为“sumPlanFlowId”,因为找不到该配置项,导致了class文件一开始就错误了。

  • 相关阅读:
    弹出层模板
    Target runtime Apache Tomcat v7.0 is not defined.解决方法
    Referenced file contains errors
    angular 双向绑定demo
    VB 6.0 ByVal ByRef 的区别
    AutoResetEvent 类的学习网站
    C# 各种定时器区分
    C# 占用系统资源少的延时
    C# API sendmessage()函数获 部分讲解 (挺不错的)
    C# API sendmessage()函数 部分讲解
  • 原文地址:https://www.cnblogs.com/zmc/p/3170018.html
Copyright © 2011-2022 走看看