Class Rectangle
Object
|
+--Shape
|
+--Rectangle
-
Direct Known Subclasses:
-
Square
- class
Rectangle
- extends Shape
A basic rectangle class, inherits from Shape.
This class could be considered a concrete implementation class
Author: Gabriel Reid
See:
Defined in test.js
|
Constructor Summary |
Rectangle(<int> width, <int> height )
Create a new Rectangle instance.
|
|
Method Summary |
int
|
getArea()
Get the value for the total area of this Rectangle
|
String
|
getClassName()
Get the type of this object.
|
int
|
getHeight()
Get the value of the height for the Rectangle.
|
int
|
getWidth()
Get the value of the width for the Rectangle
|
void
|
setHeight(<int> height)
Set the height value for this Rectangle.
|
void
|
setWidth(<int> width)
Set the width value for this Rectangle.
|
Rectangle
Rectangle(<int> width, <int> height )
Create a new Rectangle instance.
Parameters:
width - The optional width for this Rectangle
height - Thie optional height for this Rectangle
Author: Gabriel Reid
See:
getArea
int getArea()
Get the value for the total area of this Rectangle
Returns:
total area of this Rectangle
getClassName
String getClassName()
Get the type of this object.
getHeight
int getHeight()
Returns:
The height of this Rectangle
getWidth
int getWidth()
Get the value of the width for the Rectangle
setHeight
void setHeight(<int> height)
Set the height value for this Rectangle.
Parameters:
height - The height value to be set
setWidth
void setWidth(<int> width)
Set the width value for this Rectangle.
Parameters:
width - The width value to be set
Documentation generated by
JSDoc on Mon Mar 2 10:39:07 2009