日期往后加三天

SimpleDateFormat format = new SimpleDateFormat("yyyy年MM月dd日"); format.format(authentication.getCreateTime()); request.setAttribute("createTime", format.format(authentication.getCreateTime())); Calendar c = Calendar.getInstance(); c.setTime(authentication.getCreateTime()); c.add(Calendar.DAY_OF_MONTH, 3);// 今天+3天 Date finishTime = c.getTime(); request.setAttribute("finishTime", format.format(finishTime));

    原文作者:Christoz
    原文地址: https://blog.csdn.net/lihai755/article/details/70148770
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞