Package org.efs.openreports.objects.chart

Examples of org.efs.openreports.objects.chart.TimeChartValue


                SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS");
                dateFormat.setTimeZone(java.util.TimeZone.getTimeZone("UTC"));
               
        while (rs.next())
        {
          TimeChartValue timeValue = new TimeChartValue();
       
          timeValue.setSeries(rs.getString(1));         
          timeValue.setValue(rs.getDouble(2));
                   
                    if (columnType == 91 || columnType == 92 || columnType == 93) //date, time, or timestamp
                    {
                        timeValue.setTime(rs.getTimestamp(3));  
                    }
                    else
                    {                                     
                      timeValue.setTime(dateFormat.parse(rs.getString(3)));  
                    }                     

          list.add(timeValue);
        }
      }
View Full Code Here


    TimeSeries series = null;
    TimeSeriesCollection seriesCollection = new TimeSeriesCollection();

    for (int i = 0; i < values.length; i++)
    {     
      TimeChartValue value = (TimeChartValue) values[i];

      if (series == null || !series.getKey().equals(value.getSeries()))
      {
        if (series != null)
        {
          seriesCollection.addSeries(series);
        }

        series = new TimeSeries(value.getSeries(), Second.class);
      }

      series.add(new Second(value.getTime()), value.getValue());
    }

    seriesCollection.addSeries(series);

    return seriesCollection;
View Full Code Here

TOP

Related Classes of org.efs.openreports.objects.chart.TimeChartValue

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.