hades.models.io
Class HexDisplay

java.lang.Object
  extended byhades.simulator.SimObject
      extended byhades.models.io.SevenSegment
          extended byhades.models.io.HexDisplay
All Implemented Interfaces:
java.lang.Cloneable, ContextToolTip, java.io.Serializable, Simulatable

public class HexDisplay
extends SevenSegment
implements Simulatable, java.io.Serializable

HexDisplay - a simple subclass of SimObject that models a red seven-segment display with built-in decoder, used as a Hex-display 0 .. 9 A .. F.

See Also:
Serialized Form

Field Summary
(package private)  int index
           
 
Fields inherited from class hades.models.io.SevenSegment
dark_gray, display, medium_gray, segments, value_U
 
Fields inherited from class hades.simulator.SimObject
classloader, console, debug, editor, name, parent, ports, propertySheet, simulator, symbol, versionId, visible
 
Constructor Summary
HexDisplay()
          HexDisplay(): construct a four-input Hex seven-segment Hex display.
 
Method Summary
 void elaborate(java.lang.Object arg)
          elaborate: check whether the display is already visible and update our symbol.
 void evaluate(java.lang.Object arg)
          evaluate: just update our display.
 void setSymbol(Symbol s)
           
 java.lang.String toString()
          toString: generate a description with class name, full instance name and the current Hex input value.
 
Methods inherited from class hades.simulator.SimObject
configure, constructDynamicSymbol, copy, getBindkey, getClassLoader, getDebug, getEditor, getExternalResources, getFullName, getName, getParent, getPort, getPorts, getPropertySheet, getResourceAsStream, getSimulator, getSymbol, getSymbolResourceName, getToolTip, getVersionId, initialize, isVisible, keyPressed, message, mousePressed, needsDynamicSymbol, needsExternalResources, setClassLoader, setConsole, setDebug, setEditor, setName, setParent, setPorts, setSimulator, setVersionId, setVisible, tearDown, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface hades.simulator.Simulatable
message
 

Field Detail

index

int index
Constructor Detail

HexDisplay

public HexDisplay()
HexDisplay(): construct a four-input Hex seven-segment Hex display.

Method Detail

setSymbol

public void setSymbol(Symbol s)
Overrides:
setSymbol in class SevenSegment

elaborate

public void elaborate(java.lang.Object arg)
elaborate: check whether the display is already visible and update our symbol.

Specified by:
elaborate in interface Simulatable
Overrides:
elaborate in class SevenSegment
Parameters:
arg - This parameter is ignored by SevenSegment

evaluate

public void evaluate(java.lang.Object arg)
evaluate: just update our display.

Specified by:
evaluate in interface Simulatable
Overrides:
evaluate in class SevenSegment
Parameters:
arg - An arbitrary and unused object

toString

public java.lang.String toString()
toString: generate a description with class name, full instance name and the current Hex input value.

Overrides:
toString in class SevenSegment