Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## jcontrol.comm
Class DisplayConsole

    java.lang.Object
      jcontrol.comm.DisplayConsole

All Implemented Interfaces:
  ConsoleOutputStream, BasicOutputStream

    public class DisplayConsole

extends Object
implements ConsoleOutputStream

Implements a ConsoleOutputStream on the JControl Display.

Field Summary
`int` | `pos` Contains the current pixel position in the current line

Fields inherited from interface jcontrol.comm.ConsoleOutputStream
`STD_LF`

Constructor Summary
`DisplayConsole()` Constructs a new DisplayConsole using the default Display.
`DisplayConsole(Display lcd)` Constructs a new DisplayConsole using a specified Display.

Method Summary
`void` | `close()` Closes the DisplayConsole
`void` | `print(String buffer)` Writes a String to the Display.
`void` | `println()` Moves the cursor to the beginning of the next line.
`void` | `println(String buffer)` Writes a String to the Display.
`int` | `write(byte[] b, int start, int length)` Writes a character sequence to the Display.
`void` | `write(char c)` Writes a single charater to the Display.

Methods inherited from class java.lang.Object
`clone, equals, getClass, notifyAll, toString, wait`

Methods inherited from interface jcontrol.io.BasicOutputStream
`flush, write, write`

Field Detail

### pos

    public int pos

  Contains the current pixel position in the current line

Constructor Detail

### DisplayConsole

    public DisplayConsole()

  Constructs a new DisplayConsole using the default Display.

### DisplayConsole

    public DisplayConsole(Display lcd)

  Constructs a new DisplayConsole using a specified Display.

  Parameters:
    `lcd` - Display to use (full screen)

Method Detail

### write

    public void write(char c)
               throws IOException

  Writes a single charater to the Display. The cursor is moved one character to the right.

  Parameters:
    `c` - the character to write (8859-1 encoding)
  Throws:
    `IOException`

### write

    public int write(byte[] b,
                     int start,
                     int length)

  Writes a character sequence to the Display. (Not implemented)

  Specified by:
    `write` in interface `BasicOutputStream`
  Parameters:
    `b` - a byte array containing charaters to write (using 8859-1 encoding)
    `start` - index in b
    `length` - number of bytes

### print

    public void print(String buffer)

  Writes a String to the Display. The cursor is moved to the end of the characters drawn.

  Specified by:
    `print` in interface `ConsoleOutputStream`
  Parameters:
    `buffer` - the String to write
  See Also:
    `String`

### println

    public void println()

  Moves the cursor to the beginning of the next line. If needed, the display contents is scrolled up.

  Specified by:
    `println` in interface `ConsoleOutputStream`

### println

    public void println(String buffer)

  Writes a String to the Display. The cursor is moved to the beginning of the next line. If needed, the display contents is scrolled up.

  Specified by:
    `println` in interface `ConsoleOutputStream`
  Parameters:
    `buffer` - the String to write
  See Also:
    `String`

### close

    public void close()

  Closes the DisplayConsole

  Specified by:
    `close` in interface `BasicOutputStream`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD