Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.java4less.rchart.gc
Class ChartImage

    java.lang.Object
      |
      +--com.java4less.rchart.gc.ChartImage

public abstract class ChartImage
extends java.lang.Object

    Wrapper for the AWT or SWT Image class. Use GraphicsProvider.getImage() to create an instance of this class.
     This class allows rchart to work independtly from AWT and SWT.

Constructor Summary
`ChartImage()`

Method Summary
`void` | `dispose()` dispose image
`ChartGraphics` | `getGraphics()` get graphic context of the image
`int` | `getHeight()` get height of the image
`int` | `getWidth()` get width of the image
`boolean` | `saveToFile(java.lang.String sFormat, java.lang.String file)` saves image to a file
`boolean` | `saveToStream(java.lang.String sFormat, java.io.OutputStream os)` saves image to an output stream

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ChartImage

    public ChartImage()

Method Detail

### getGraphics

    public ChartGraphics getGraphics()

  get graphic context of the image

  Returns:

### getWidth

    public int getWidth()

  get width of the image

  Returns:

### getHeight

    public int getHeight()

  get height of the image

  Returns:

### saveToFile

    public boolean saveToFile(java.lang.String sFormat,
                              java.lang.String file)
                       throws java.lang.Exception

  saves image to a file

  Parameters:
    `sFormat` - GIF,PNG or JPEG
    `file` -
  Returns:
  Throws:
    `java.lang.Exception`

### saveToStream

    public boolean saveToStream(java.lang.String sFormat,
                                java.io.OutputStream os)

  saves image to an output stream

  Parameters:
    `sFormat` - GIF,PNG or JPEG
  Returns:

### dispose

    public void dispose()

  dispose image

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD