net.moioli.chart
Class DefaultChart

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractSet<E>
          extended by java.util.HashSet
              extended by net.moioli.chart.AbstractChart
                  extended by net.moioli.chart.DefaultChart
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.Set, ChartI

public class DefaultChart
extends AbstractChart
implements ChartI

A simple yet complete implementation of the ChartI interface. It includes the xy axes, the MoioChart logo and a Legend by default.

Version:
2005/10/5
Author:
Silvio Moioli
See Also:
DrawableI, GraphicsI, Serialized Form

Constructor Summary
DefaultChart()
          Builds an empty DefaultChart.
DefaultChart(java.util.Collection c)
          Builds an DefaultChart with the specified objects.
 
Method Summary
 void drawMe(GraphicsI g, IntRectangle clip)
          Draws this DefaultChart on the passed GraphicsI surface.
 
Methods inherited from class net.moioli.chart.AbstractChart
add, getMaxX, getMaxY, getMinX, getMinY, getPixelAccuracy, setMaxX, setMaxY, setMinX, setMinY, setPixelAccuracy
 
Methods inherited from class java.util.HashSet
clear, clone, contains, isEmpty, iterator, remove, size
 
Methods inherited from class java.util.AbstractSet
equals, hashCode, removeAll
 
Methods inherited from class java.util.AbstractCollection
addAll, containsAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.moioli.chart.ChartI
add, getMaxX, getMaxY, getMinX, getMinY, getPixelAccuracy, setMaxX, setMaxY, setMinX, setMinY, setPixelAccuracy
 
Methods inherited from interface java.util.Set
addAll, containsAll, equals, hashCode, removeAll, retainAll, toArray, toArray
 

Constructor Detail

DefaultChart

public DefaultChart()
Builds an empty DefaultChart.


DefaultChart

public DefaultChart(java.util.Collection c)
Builds an DefaultChart with the specified objects.

Parameters:
c - Collection of DrawableI objects
Method Detail

drawMe

public void drawMe(GraphicsI g,
                   IntRectangle clip)
Description copied from interface: ChartI
Draws this DefaultChart on the passed GraphicsI surface.

Specified by:
drawMe in interface ChartI
Specified by:
drawMe in class AbstractChart
Parameters:
g - the surface where this DefaultChart will be drawn
clip - the clipping rectangle to be used for drawing
See Also:
ChartI.drawMe(net.moioli.chart.GraphicsI, net.moioli.chart.IntRectangle)