美文网首页
对象Bean转xml时报com.sun.istack.inter

对象Bean转xml时报com.sun.istack.inter

作者: 夜色001 | 来源:发表于2021-09-16 16:40 被阅读0次

    异常现象


    image.png
    HotelOtherCancelConfigEntity cancelConfigEntity = collect.get(0);
                    CancelPenaltyType cancelPenalty = new CancelPenaltyType();
                    AmountPercentType amountPercent = new RatePlanType.Guarantee.AmountPercent();
                    amountPercent.setBasisType(cancelConfigEntity.getDeductionType() == 1 ? "FirstLast" : (cancelConfigEntity.getDeductionType() == 2 ? "FullStay" : ""));
                    cancelPenalty.setAmountPercent(amountPercent);
                    CancelPenaltyType.Deadline deadline = new CancelPenaltyType.Deadline();
                    deadline.setOffsetDropTime("BeforeArrival");
                    deadline.setOffsetTimeUnit(TimeUnitType.HOUR);
                    Integer hours = calcCancelHours(cancelConfigEntity);
                    deadline.setOffsetUnitMultiplier(hours);
                    cancelPenalty.setDeadline(deadline);
                    cancelPenaltyLst.add(cancelPenalty);
    


    AmountPercentType amountPercent = new RatePlanType.Guarantee.AmountPercent();
    改为
    AmountPercentType amountPercent = new AmountPercentType ();

    相关文章

      网友评论

          本文标题:对象Bean转xml时报com.sun.istack.inter

          本文链接:https://www.haomeiwen.com/subject/skargltx.html