Package de.intranda.commons.chart.renderer

Examples of de.intranda.commons.chart.renderer.IRenderer


   * generate chart at defined folder of datatable
   *************************************************************************************/
  private void createChart(Boolean inShowAverage) {
    imageUrl = System.currentTimeMillis() + ".png";

    IRenderer renderer = null;
    if (dataTable.isShowableInPieChart()) {
      renderer = new PieChartRenderer();
    } else {
      ChartRenderer crenderer = new ChartRenderer();
      crenderer.setShowMeanValues(inShowAverage);
      renderer = crenderer;
    }
    if (myQuestion.isRendererInverted(renderer)) {
      renderer.setDataTable(dataTable.getDataTableInverted());
    } else {
      renderer.setDataTable(dataTable);
    }
    File outputfile = new File(localImagePath + imageUrl);
    BufferedImage image = (BufferedImage) renderer.getRendering();
    try {
      ImageIO.write(image, "png", outputfile);
    } catch (IOException e) {
      logger.error(e);
    }
View Full Code Here


    test.setCalculationUnit(CalculationUnit.pages);
  }

  @Test
  public void testIsRendererInverted() {
    IRenderer inRenderer = new ChartRenderer();
    assertTrue(test.isRendererInverted(inRenderer));
  }
View Full Code Here

    test.setTimeFrame(cal1.getTime(), cal2.getTime());
  }

  @Test
  public final void testIsRendererInverted() {
    IRenderer inRenderer = new ChartRenderer();
    assertTrue(test.isRendererInverted(inRenderer));
  }
View Full Code Here

    test.setTimeFrame(cal1.getTime(), cal2.getTime());
  }

  @Test
  public void testIsRendererInverted() {
    IRenderer inRenderer = new ChartRenderer();
    IRenderer inRenderer2 = new HtmlTableRenderer();
    assertFalse(test.isRendererInverted(inRenderer2));
    assertTrue(test.isRendererInverted(inRenderer));
  }
View Full Code Here

    assertNotNull(table);
  }

  @Test
  public void testIsRendererInverted() {
    IRenderer inRenderer = new ChartRenderer();
    IRenderer inRenderer2 = new HtmlTableRenderer();
    assertFalse(test.isRendererInverted(inRenderer));
    assertTrue(test.isRendererInverted(inRenderer2));
  }
View Full Code Here

    test.setTimeFrame(cal1.getTime(), cal2.getTime());
  }

  @Test
  public void testIsRendererInverted() {
    IRenderer inRenderer = new ChartRenderer();
    IRenderer inRenderer2 = new HtmlTableRenderer();
    assertFalse(test.isRendererInverted(inRenderer2));
    assertTrue(test.isRendererInverted(inRenderer));
  }
View Full Code Here

TOP

Related Classes of de.intranda.commons.chart.renderer.IRenderer

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.