All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class duckMachine.GUI.ioUnitPanel

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----duckMachine.GUI.ioUnitPanel

public class ioUnitPanel
extends Panel
A panel for the IO unit.


Constructor Index

 o ioUnitPanel(MachineFrame, ioUnitI, InputStream, OutputStream)
The IO panel communiates with the IO port of the machine via pipes.

Method Index

 o updatePanel(ioUnitI)

Constructors

 o ioUnitPanel
 public ioUnitPanel(MachineFrame mf,
                    ioUnitI io,
                    InputStream fmach,
                    OutputStream tmach)
The IO panel communiates with the IO port of the machine via pipes. Every key typed in the input window of the panel is written to the machine's input pipe. When a machine's command finishes the contents of the machine's output pipe are appended to the output window of the panel. Care must be taken to flush the streams at the appropriate time otherwise the whole thing can block!

Methods

 o updatePanel
 public void updatePanel(ioUnitI io) throws IOException
Throws: IOException
If the update of the output port causes an error.

All Packages  Class Hierarchy  This Package  Previous  Next  Index