// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3)
package demo;
import java.awt.*;
import java.text.SimpleDateFormat;
import javax.swing.JPanel;
import org.jfree.chart.*;
import org.jfree.chart.axis.DateAxis;
import org.jfree.chart.axis.DateTickMarkPosition;
import org.jfree.chart.labels.StandardXYToolTipGenerator;
import org.jfree.chart.plot.IntervalMarker;
import org.jfree.chart.plot.XYPlot;
import org.jfree.chart.renderer.xy.XYDifferenceRenderer;
import org.jfree.chart.title.TextTitle;
import org.jfree.data.time.*;
import org.jfree.data.xy.XYDataset;
import org.jfree.ui.*;
public class DifferenceChartDemo2 extends ApplicationFrame
{
public DifferenceChartDemo2(String s)
{
super(s);
JPanel jpanel = createDemoPanel();
jpanel.setPreferredSize(new Dimension(500, 270));
setContentPane(jpanel);
}
private static XYDataset createDataset()
{
TimeSeries timeseries = createSunriseSeries();
TimeSeries timeseries1 = createSunsetSeries();
TimeSeriesCollection timeseriescollection = new TimeSeriesCollection();
timeseriescollection.addSeries(timeseries);
timeseriescollection.addSeries(timeseries1);
return timeseriescollection;
}
private static Long time(int i, int j)
{
Minute minute = new Minute(j, i, 1, 1, 1970);
return new Long(minute.getFirstMillisecond());
}
public static TimeSeries createSunriseSeries()
{
TimeSeries timeseries = new TimeSeries("Sunrise");
timeseries.add(new Day(1, 1, 2004), time(8, 5));
timeseries.add(new Day(2, 1, 2004), time(8, 5));
timeseries.add(new Day(3, 1, 2004), time(8, 5));
timeseries.add(new Day(4, 1, 2004), time(8, 5));
timeseries.add(new Day(5, 1, 2004), time(8, 5));
timeseries.add(new Day(6, 1, 2004), time(8, 4));
timeseries.add(new Day(7, 1, 2004), time(8, 4));
timeseries.add(new Day(8, 1, 2004), time(8, 4));
timeseries.add(new Day(9, 1, 2004), time(8, 3));
timeseries.add(new Day(10, 1, 2004), time(8, 3));
timeseries.add(new Day(11, 1, 2004), time(8, 2));
timeseries.add(new Day(12, 1, 2004), time(8, 1));
timeseries.add(new Day(13, 1, 2004), time(8, 1));
timeseries.add(new Day(14, 1, 2004), time(8, 0));
timeseries.add(new Day(15, 1, 2004), time(7, 59));
timeseries.add(new Day(16, 1, 2004), time(7, 58));
timeseries.add(new Day(17, 1, 2004), time(7, 58));
timeseries.add(new Day(18, 1, 2004), time(7, 57));
timeseries.add(new Day(19, 1, 2004), time(7, 56));
timeseries.add(new Day(20, 1, 2004), time(7, 55));
timeseries.add(new Day(21, 1, 2004), time(7, 54));
timeseries.add(new Day(22, 1, 2004), time(7, 53));
timeseries.add(new Day(23, 1, 2004), time(7, 51));
timeseries.add(new Day(24, 1, 2004), time(7, 50));
timeseries.add(new Day(25, 1, 2004), time(7, 49));
timeseries.add(new Day(26, 1, 2004), time(7, 48));
timeseries.add(new Day(27, 1, 2004), time(7, 46));
timeseries.add(new Day(28, 1, 2004), time(7, 45));
timeseries.add(new Day(29, 1, 2004), time(7, 44));
timeseries.add(new Day(30, 1, 2004), time(7, 42));
timeseries.add(new Day(31, 1, 2004), time(7, 41));
timeseries.add(new Day(1, 2, 2004), time(7, 39));
timeseries.add(new Day(2, 2, 2004), time(7, 38));
timeseries.add(new Day(3, 2, 2004), time(7, 36));
timeseries.add(new Day(4, 2, 2004), time(7, 35));
timeseries.add(new Day(5, 2, 2004), time(7, 33));
timeseries.add(new Day(6, 2, 2004), time(7, 31));
timeseries.add(new Day(7, 2, 2004), time(7, 30));
timeseries.add(new Day(8, 2, 2004), time(7, 28));
timeseries.add(new Day(9, 2, 2004), time(7, 26));
timeseries.add(new Day(10, 2, 2004), time(7, 25));
timeseries.add(new Day(11, 2, 2004), time(7, 23));
timeseries.add(new Day(12, 2, 2004), time(7, 21));
timeseries.add(new Day(13, 2, 2004), time(7, 19));
timeseries.add(new Day(14, 2, 2004), time(7, 17));
timeseries.add(new Day(15, 2, 2004), time(7, 15));
timeseries.add(new Day(16, 2, 2004), time(7, 13));
timeseries.add(new Day(17, 2, 2004), time(7, 11));
timeseries.add(new Day(18, 2, 2004), time(7, 10));
timeseries.add(new Day(19, 2, 2004), time(7, 8));
timeseries.add(new Day(20, 2, 2004), time(7, 6));
timeseries.add(new Day(21, 2, 2004), time(7, 4));
timeseries.add(new Day(22, 2, 2004), time(7, 2));
timeseries.add(new Day(23, 2, 2004), time(6, 59));
timeseries.add(new Day(24, 2, 2004), time(6, 57));
timeseries.add(new Day(25, 2, 2004), time(6, 55));
timeseries.add(new Day(26, 2, 2004), time(6, 53));
timeseries.add(new Day(27, 2, 2004), time(6, 51));
timeseries.add(new Day(28, 2, 2004), time(6, 49));
timeseries.add(new Day(29, 2, 2004), time(6, 47));
timeseries.add(new Day(1, 3, 2004), time(6, 45));
timeseries.add(new Day(2, 3, 2004), time(6, 43));
timeseries.add(new Day(3, 3, 2004), time(6, 40));
timeseries.add(new Day(4, 3, 2004), time(6, 38));
timeseries.add(new Day(5, 3, 2004), time(6, 36));
timeseries.add(new Day(6, 3, 2004), time(6, 34));
timeseries.add(new Day(7, 3, 2004), time(6, 32));
timeseries.add(new Day(8, 3, 2004), time(6, 29));
timeseries.add(new Day(9, 3, 2004), time(6, 27));
timeseries.add(new Day(10, 3, 2004), time(6, 25));
timeseries.add(new Day(11, 3, 2004), time(6, 23));
timeseries.add(new Day(12, 3, 2004), time(6, 20));
timeseries.add(new Day(13, 3, 2004), time(6, 18));
timeseries.add(new Day(14, 3, 2004), time(6, 16));
timeseries.add(new Day(15, 3, 2004), time(6, 14));
timeseries.add(new Day(16, 3, 2004), time(6, 11));
timeseries.add(new Day(17, 3, 2004), time(6, 9));
timeseries.add(new Day(18, 3, 2004), time(6, 7));
timeseries.add(new Day(19, 3, 2004), time(6, 5));
timeseries.add(new Day(20, 3, 2004), time(6, 2));
timeseries.add(new Day(21, 3, 2004), time(6, 0));
timeseries.add(new Day(22, 3, 2004), time(5, 58));
timeseries.add(new Day(23, 3, 2004), time(5, 55));
timeseries.add(new Day(24, 3, 2004), time(5, 53));
timeseries.add(new Day(25, 3, 2004), time(5, 51));
timeseries.add(new Day(26, 3, 2004), time(5, 49));
timeseries.add(new Day(27, 3, 2004), time(5, 46));
timeseries.add(new Day(28, 3, 2004), time(6, 44));
timeseries.add(new Day(29, 3, 2004), time(6, 42));
timeseries.add(new Day(30, 3, 2004), time(6, 39));
timeseries.add(new Day(31, 3, 2004), time(6, 37));
timeseries.add(new Day(1, 4, 2004), time(6, 35));
timeseries.add(new Day(2, 4, 2004), time(6, 33));
timeseries.add(new Day(3, 4, 2004), time(6, 30));
timeseries.add(new Day(4, 4, 2004), time(6, 28));
timeseries.add(new Day(5, 4, 2004), time(6, 26));
timeseries.add(new Day(6, 4, 2004), time(6, 24));
timeseries.add(new Day(7, 4, 2004), time(6, 21));
timeseries.add(new Day(8, 4, 2004), time(6, 19));
timeseries.add(new Day(9, 4, 2004), time(6, 17));
timeseries.add(new Day(10, 4, 2004), time(6, 15));
timeseries.add(new Day(11, 4, 2004), time(6, 12));
timeseries.add(new Day(12, 4, 2004), time(6, 10));
timeseries.add(new Day(13, 4, 2004), time(6, 8));
timeseries.add(new Day(14, 4, 2004), time(6, 6));
timeseries.add(new Day(15, 4, 2004), time(6, 4));
timeseries.add(new
评论1