All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class cs101.canvas.Oval

java.lang.Object
   |
   +----cs101.canvas.GraphicsObject
           |
           +----cs101.canvas.ResizableObject
                   |
                   +----cs101.canvas.FilledObject
                           |
                           +----cs101.canvas.Oval

public class Oval
extends FilledObject
A GraphicsObject that represents a geometric oval


Constructor Index

 o Oval(int, int, int, int)
Construct a new Oval with black as the default color
 o Oval(int, int, int, int, Color)
Construct a new Oval with the passed color

Method Index

 o draw(Graphics)

Constructors

 o Oval
 public Oval(int x,
             int y,
             int width,
             int height)
Construct a new Oval with black as the default color

Parameters:
x - x coordinate of left side
y - y coordinate of top side
width - width of the oval
height - height of the oval
Returns:
none
 o Oval
 public Oval(int x,
             int y,
             int width,
             int height,
             Color graphicsColor)
Construct a new Oval with the passed color

Parameters:
x - x coordinate of left side
y - y coordinate of top side
width - width of the oval
height - height of the oval
graphicsColor - color of the oval
Returns:
none

Methods

 o draw
 public void draw(Graphics g)
Overrides:
draw in class GraphicsObject

All Packages  Class Hierarchy  This Package  Previous  Next  Index