01 2016 档案

摘要:JavaDecimalFormat dcmFmt = new DecimalFormat("0.00");double db = 12333.353;System.out.println(dcmFmt.format(db));JS 阅读全文
posted @ 2016-01-26 10:00 阿窟窿 阅读(4240) 评论(0) 推荐(0)
摘要:两个Date类型的变量可以通过compareTo方法来比较。此方法的描述是这样的:如果参数 Date 等于此 Date,则返回值 0;如果此 Date 在 Date 参数之前,则返回小于 0 的值;如果此 Date 在 Date 参数之后,则返回大于 0 的值。实际上比较的是自1970 年 1 月 ... 阅读全文
posted @ 2016-01-26 09:57 阿窟窿 阅读(1589) 评论(0) 推荐(0)
摘要:1.Calendar 转化 StringCalendar calendat = Calendar.getInstance();SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");String dateStr = sdf.format(c... 阅读全文
posted @ 2016-01-25 10:36 阿窟窿 阅读(794) 评论(0) 推荐(0)
摘要:Calendar cal = Calendar.getInstance(); int year =cal.get(Calendar.YEAR)+1; int month=cal.get(Calendar.MONTH)+1; cal.add(Calendar.MONTH... 阅读全文
posted @ 2016-01-21 16:21 阿窟窿 阅读(11832) 评论(0) 推荐(0)