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

## org.ascape.runtime
Class RuntimeEnvironment

    java.lang.Object
      org.ascape.model.event.DefaultScapeListener
          org.ascape.runtime.RuntimeEnvironment

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable, java.util.EventListener, ScapeListener, HasName

Direct Known Subclasses:
  AbstractUIEnvironment

    public class RuntimeEnvironment

extends DefaultScapeListener

Supports all non-ui shared aspects of Ascape runtime environment, including console view, managing environment views, etc..

Since:
  3.0
Version:
  3.0
See Also:
  Serialized Form

Field Summary

Fields inherited from class org.ascape.model.event.DefaultScapeListener
`listeningToScape, name, scape`

Constructor Summary
`RuntimeEnvironment()` Instantiates a new runtime environment.

Method Summary
`void` | `addView(ScapeListener view)` Adds the view.
`void` | `addView(ScapeListener view, boolean createFrame)` Adds the view.
`void` | `addViews(ScapeListener[] views)` Adds the views.
`void` | `addViews(ScapeListener[] views, boolean createFrame)` Adds the views.
`void` | `environmentQuiting(ScapeEvent scapeEvent)` Setup up a basic interactive controlBar time userEnvironment for a model application.
`static void` | `exit()` Final kill.
`ConsoleOutView` | `getConsole()` Gets the consoleOutView for the ModelRoot object.
`java.util.ArrayList` | `getEnvironmentViews()` Gets the environment views.
`void` | `quit()` Exits the application; allowing views to close themseleves gracefully.
`void` | `removeView(ScapeListener view)` Removes the view.
`void` | `removeViews(ScapeListener[] views)` Removes the views.
`void` | `scapeAdded(ScapeEvent scapeEvent)` When a scape is added add any persiten views to it and set frame title.
`void` | `setConsole(ConsoleOutView consoleOutView)` Sets consoleOutView for the ModelRoot object.

Methods inherited from class org.ascape.model.event.DefaultScapeListener
`clone, getName, getScape, isGraphic, isLifeOfScape, isNotifyScapeAutomatically, notifyScapeUpdated, scapeClosing, scapeDeserialized, scapeInitialized, scapeIterated, scapeNotification, scapeRemoved, scapeSetup, scapeStarted, scapeStopped, setName, setNotifyScapeAutomatically, toString`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### RuntimeEnvironment

    public RuntimeEnvironment()

  Instantiates a new runtime environment.

Method Detail

### addView

    public void addView(ScapeListener view,
                        boolean createFrame)

  Adds the view.

  Parameters:
    `view` - the view
    `createFrame` - the create frame

### addView

    public void addView(ScapeListener view)

  Adds the view.

  Parameters:
    `view` - the view

### addViews

    public void addViews(ScapeListener[] views)

  Adds the views.

  Parameters:
    `views` - the views

### addViews

    public void addViews(ScapeListener[] views,
                         boolean createFrame)

  Adds the views.

  Parameters:
    `views` - the views
    `createFrame` - the create frame

### removeView

    public void removeView(ScapeListener view)

  Removes the view.

  Parameters:
    `view` - the view

### removeViews

    public void removeViews(ScapeListener[] views)

  Removes the views.

  Parameters:
    `views` - the views

### environmentQuiting

    public void environmentQuiting(ScapeEvent scapeEvent)

  Setup up a basic interactive controlBar time userEnvironment for a model application.

  Specified by:
    `environmentQuiting` in interface `ScapeListener`
  Overrides:
    `environmentQuiting` in class `DefaultScapeListener`
  Parameters:
    `scapeEvent` - the scape event

### quit

    public void quit()

  Exits the application; allowing views to close themseleves gracefully. Do not call this method directly unless you want to force quit; call `quit()` instead, allowing a running scape to stop gracefully. Override this method if you want to provide any scape related pre-quit finalization or clean-up.

  See Also:
    `quit()`

### exit

    public static void exit()

  Final kill. Calls System exit, which appears neccessary for vm even when code has finished.

### scapeAdded

    public void scapeAdded(ScapeEvent scapeEvent)
                    throws java.util.TooManyListenersException

  When a scape is added add any persiten views to it and set frame title.

  Specified by:
    `scapeAdded` in interface `ScapeListener`
  Overrides:
    `scapeAdded` in class `DefaultScapeListener`
  Parameters:
    `scapeEvent` - the scape event
  Throws:
    `java.util.TooManyListenersException` - the too many listeners exception

### getConsole

    public ConsoleOutView getConsole()

  Gets the consoleOutView for the ModelRoot object.

  Returns:
    the consoleOutView

### setConsole

    public void setConsole(ConsoleOutView consoleOutView)

  Sets consoleOutView for the ModelRoot object.

  Parameters:
    `consoleOutView` - the consoleOutView

### getEnvironmentViews

    public java.util.ArrayList getEnvironmentViews()

  Gets the environment views.

  Returns:
    the environment views

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