frysk.rt
Class DisplayManager

java.lang.Object
  extended by frysk.rt.DisplayManager

public class DisplayManager
extends Object

The DisplayManager is in charge of keeping track of the UpdatingDisplayValues currently in existence


Constructor Summary
DisplayManager()
           
 
Method Summary
static UpdatingDisplayValue createDisplay(Task myTask, FrameIdentifier fIdent, SteppingEngine engine, String text)
          Creates a new UpdatingDisplayValue if no such display exists yet.
static boolean deleteDisplay(int num)
          Deletes the display with the given identifier.
static void deleteDisplay(UpdatingDisplayValue value)
          Removes an UpdatingDisplayValue from the manager, allowing it to be garbage collected
static boolean disableDisplay(int num)
          Disables the display with the given identifier.
static boolean enableDisplay(int num)
          Enables the display with the given identifier.
static UpdatingDisplayValue getDisplay(int id)
          Retreive the display with the provided identifier if it exists.
static Iterator getDisplayIterator()
          Allows retrieval of all the displays being tracked by this manager
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DisplayManager

public DisplayManager()
Method Detail

createDisplay

public static UpdatingDisplayValue createDisplay(Task myTask,
                                                 FrameIdentifier fIdent,
                                                 SteppingEngine engine,
                                                 String text)
Creates a new UpdatingDisplayValue if no such display exists yet. If one already exists it is returned instead

Parameters:
myTask - The task the displayed expression is from
fIdent - The frame the displayed expression is from
engine - The stepping engine controlling the task
text - The expression text to create a display for
Returns:

deleteDisplay

public static void deleteDisplay(UpdatingDisplayValue value)
Removes an UpdatingDisplayValue from the manager, allowing it to be garbage collected

Parameters:
value - The display to remove

disableDisplay

public static boolean disableDisplay(int num)
Disables the display with the given identifier. If no display exists with that identifier nothing is done.

Parameters:
num - The unique ID of the display to disable
Returns:
true if a display was disabled, false otherwise

enableDisplay

public static boolean enableDisplay(int num)
Enables the display with the given identifier. If no display exists with that number nothing is done

Parameters:
num - The unique ID of the identifier to enable
Returns:
True if an identifier was enabled, false otherwise

deleteDisplay

public static boolean deleteDisplay(int num)
Deletes the display with the given identifier. If no display exists with that identifier nothing is done.

Parameters:
num - The unique ID of the display to delete
Returns:
true if a display was deleted, false otherwise

getDisplayIterator

public static Iterator getDisplayIterator()
Allows retrieval of all the displays being tracked by this manager

Returns:
An iterator of all the displays known to the manager

getDisplay

public static UpdatingDisplayValue getDisplay(int id)
Retreive the display with the provided identifier if it exists. If no display exists then null is returned.

Parameters:
id - The identifier of the display to fetch
Returns:
The display with the given id, or null if no such display exists