com.nordija.tapestry.bayeux.stream.jfreechart
Class SimpleJFreeChartResource

java.lang.Object
  extended by com.nordija.tapestry.bayeux.stream.jfreechart.JFreeChartResource
      extended by com.nordija.tapestry.bayeux.stream.jfreechart.SimpleJFreeChartResource
All Implemented Interfaces:
StreamResource

public class SimpleJFreeChartResource
extends JFreeChartResource

A simple implementation of the JFreeChartResource where all the data is given in the constructor.

This implementation defines no content-disposition header

Author:
Jacob von Eyben - Nordija A/S

Constructor Summary
SimpleJFreeChartResource(org.jfree.chart.JFreeChart chart, int height, int width, java.lang.String imageFormat)
           
 
Method Summary
 java.lang.String getContentDisposition()
           
 int getHeight()
          The height of the streamed chart
 java.lang.String getImageFormat()
          The image format of the chart.
 int getWidth()
          The width of the streamed chart
 
Methods inherited from class com.nordija.tapestry.bayeux.stream.jfreechart.JFreeChartResource
getContentType, writeTo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleJFreeChartResource

public SimpleJFreeChartResource(org.jfree.chart.JFreeChart chart,
                                int height,
                                int width,
                                java.lang.String imageFormat)
Method Detail

getImageFormat

public java.lang.String getImageFormat()
Description copied from class: JFreeChartResource

The image format of the chart. Can be one of the following:
ImageFormat.JPEG or ImageFormat.PNG

Specified by:
getImageFormat in class JFreeChartResource
Returns:
a image format for the chart

getHeight

public int getHeight()
Description copied from class: JFreeChartResource
The height of the streamed chart

Specified by:
getHeight in class JFreeChartResource
Returns:
the height

getWidth

public int getWidth()
Description copied from class: JFreeChartResource
The width of the streamed chart

Specified by:
getWidth in class JFreeChartResource
Returns:
the width

getContentDisposition

public java.lang.String getContentDisposition()


Copyright © 2004-2007 Nordija A/S. All Rights Reserved.