Class DataView

  extended by org.ascape.model.event.DefaultScapeListener
      extended by org.ascape.view.nonvis.NonGraphicView
          extended by org.ascape.view.nonvis.DataView
All Implemented Interfaces:, java.lang.Cloneable, java.util.EventListener, ScapeListener, HasName
Direct Known Subclasses:
ConsoleOutView, DataOutputView

public class DataView
extends NonGraphicView

A non-graphic view providing output of model data to a file. To use, (assuming you are collecting the statistics you are interested in, see Scape) just add this view to any scape, and set a file or data strem for it. Every period, statistic measurements will be written to the file or data strem. By default, all statistics are selected; get data selection to make different selections. DataOutputView provides an implementation of this class that handles multiple files and runs.

1.2 8/4/99
Miles Parker
See Also:
DataOutputView, Scape, Serialized Form

Field Summary
protected  DataSelection dataSelection
          The selection of data that is be written.
Fields inherited from class org.ascape.model.event.DefaultScapeListener
listeningToScape, name, scape
Constructor Summary
Method Summary
 DataSelection getDataSelection()
          Returns the data group selection for this data output view.
 void scapeAdded(ScapeEvent scapeEvent)
          Notifies the listener that the scape has added it.
Methods inherited from class org.ascape.view.nonvis.NonGraphicView
Methods inherited from class org.ascape.model.event.DefaultScapeListener
clone, environmentQuiting, getName, getScape, 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

Field Detail


protected DataSelection dataSelection
The selection of data that is be written.

Constructor Detail


public DataView()
Method Detail


public DataSelection getDataSelection()
Returns the data group selection for this data output view. Selected data series will be exported to the file. By default, all series are selected.

the data selection


public void scapeAdded(ScapeEvent scapeEvent)
                throws java.util.TooManyListenersException
Notifies the listener that the scape has added it. Creates a new data selection for data output, backed by the Scape's data group.

Specified by:
scapeAdded in interface ScapeListener
scapeAdded in class DefaultScapeListener
scapeEvent - the scape added notification event
java.util.TooManyListenersException - the too many listeners exception
java.util.TooManyListenersException - on attempt to add this listener to another scape when one has already been assigned

Copyright © 1998-2008 The Brookings Institution, NuTech Solutions, Metascape, LLC All Rights Reserved.