我正在尝试实现 Jfreechart API,但我遇到了问题:
这是我的代码
/**Adding data in this series**/
seriesOne.add(new Task("Project Progress Bar",
new SimpleTimePeriod(makeDate(25, Calendar.JUNE, 2013),
makeDate(30, Calendar.JUNE, 2013))));
/**adding second task**/
/**Adding data in this series**/
seriesTwo.add(new Task("Project Progress Bar",
new SimpleTimePeriod(makeDate(28, Calendar.JUNE, 2013),
makeDate(30, Calendar.JUNE, 2013))));
makeDate 方法
private static Date makeDate(final int day, final int month, final int year) {
final Calendar calendar = Calendar.getInstance();
calendar.set(year, month, day);
final Date result = calendar.getTime();
return result;
}
我需要传递d1="2011-03-06" d2="2011-05-06" d3="2011-05-06" d4="2011-05-06"
而不是对日期进行编码,我该怎么做
new SimpleTimePeriod(makeDate(d1),
makeDate(d2))));
感谢任何帮助将不胜感激请