Class HLine

java.lang.Object
  extended byLine
      extended byHLine

public class HLine
extends Line

An HLine is a horizontal Line.


Field Summary
 
Fields inherited from class Line
length, paintChar
 
Constructor Summary
HLine(int length, char paintChar)
          Construct an HLine having a paintChar and a length.
 
Method Summary
static void main(String[] args)
          Unit test for class HLine.
 void paintOn(Screen screen, int x, int y)
          Paint this Line on Screen s at position (x,y).
 
Methods inherited from class Line
getLength, getPaintChar, paintOn, setLength, setPaintChar
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HLine

public HLine(int length,
             char paintChar)
Construct an HLine having a paintChar and a length.

Parameters:
length - length in (character) pixels.
paintChar - character used for painting this Line.
Method Detail

main

public static void main(String[] args)
Unit test for class HLine.


paintOn

public void paintOn(Screen screen,
                    int x,
                    int y)
Paint this Line on Screen s at position (x,y).

Specified by:
paintOn in class Line
Parameters:
screen - the Screen on which this Line is to be painted.
x - the x position for the line.
y - the y position for the line.