閱碼場 Linux內(nèi)核tracers的實現(xiàn)原理與應(yīng)用
?distance = ChronoUnit.DAYS.between(startDate, endDate);
? ? ? ? ? ?Stream.iterate(startDate, d -> d.plusDays(1)).limit(distance + 1).forEach(f -> list.add(f.toString()));
? ? ? ?} else if(type==2) {
? ? ? ? ? ?distance = ChronoUnit.MONTHS.between(startDate, endDate);
? ? ? ? ? ?Stream.iterate(startDate, d -> d.plusMonths(1)).limit(distance + 1).forEach(f -> list.add(f.toString().substring(0,7)));
? ? ? ?}
? ? ? ?return list;
? ?}
標簽: