Class wb.GraphSpoke
All Packages Class Hierarchy This Package Previous Next Index
Class wb.GraphSpoke
java.lang.Object
|
+----wb.GraphUnit
|
+----wb.GraphPolyLine
|
+----wb.GraphSpoke
- public class GraphSpoke
- extends GraphPolyLine
Intended to describe Splines for now it is spokes...
Maps the base class member variables
(xmin, ymin) as the starting point
(xmax or ymax) --> the number of points in the polygon
Limit to a max of 40 points
-
GraphSpoke(int, int, Color)
- Creates an Instance of Spokes with its first point set along with
the Color and type
-
GraphSpoke(DataInputStream)
- Creates an instance of the GraphSpoke by reading the data from the
Input Stream.
-
erase(Graphics, Color)
- Paints the object using the background color to the canvas/screen
-
isInside(int, int)
- method to verify if the passed point is enclosed in the handles
of this Object.
-
paint(Graphics)
- Does the real work of painting the object to the canvas/screen
GraphSpoke
public GraphSpoke(int x,
int y,
Color arg)
- Creates an Instance of Spokes with its first point set along with
the Color and type
- Parameters:
- x1 - the x coordinate of the first point
- y1 - the y coordinate of the first point
- arg - the color of this rectangle.
- See Also:
- addnext, GTypes
GraphSpoke
public GraphSpoke(DataInputStream din) throws IOException
- Creates an instance of the GraphSpoke by reading the data from the
Input Stream. It then fills up the member variables of the class
- Parameters:
- din - DataInputStream the stream from which the data is read
- Throws: IOException
- if an I/O error occurs
- See Also:
- ByteUnPackInputStream, packetize
paint
public void paint(Graphics g)
- Does the real work of painting the object to the canvas/screen
- Parameters:
- g - Graphics on to which the object is rendered
- Overrides:
- paint in class GraphPolyLine
erase
public void erase(Graphics g,
Color arg)
- Paints the object using the background color to the canvas/screen
- Parameters:
- g - Graphics on to which the object is rendered
- arg - Color of the background
- Overrides:
- erase in class GraphPolyLine
- See Also:
- erase
isInside
public boolean isInside(int x,
int y)
- method to verify if the passed point is enclosed in the handles
of this Object.
- Parameters:
- x - x-coordinate of the point
- y - y-coordinate of the point
- Returns:
- boolean true iff the point is enclosed in the handles
- Overrides:
- isInside in class GraphPolyLine
All Packages Class Hierarchy This Package Previous Next Index