jcckit.graphic
Class Oval

java.lang.Object
  extended byjcckit.graphic.BasicGraphicalElement
      extended byjcckit.graphic.Rectangle
          extended byjcckit.graphic.Oval
All Implemented Interfaces:
GraphicalElement

public class Oval
extends Rectangle

An oval (i.e. an ellipse).

Author:
Franz-Josef Elmer

Constructor Summary
Oval(GraphPoint center, double width, double height, GraphicAttributes attributes)
          Creates a new instance.
 
Method Summary
 void renderWith(Renderer renderer)
          Renders this oval with the specified Renderer.
 
Methods inherited from class jcckit.graphic.Rectangle
getCenter, getHeight, getWidth
 
Methods inherited from class jcckit.graphic.BasicGraphicalElement
getGraphicAttributes, isClosed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Oval

public Oval(GraphPoint center,
            double width,
            double height,
            GraphicAttributes attributes)
Creates a new instance.

Parameters:
center - The position of the center of this element.
width - The width.
height - The height.
attributes - Drawing attributes. Can be null.
Method Detail

renderWith

public void renderWith(Renderer renderer)
Renders this oval with the specified Renderer.

Specified by:
renderWith in interface GraphicalElement
Overrides:
renderWith in class Rectangle
Parameters:
renderer - An instance of OvalRenderer.
Throws:
java.lang.IllegalArgumentException - if renderer is not an instance of OvalRenderer.