datavisualizer.StormDataRequest Class Reference

Produces a table of storm results. More...

Inheritance diagram for datavisualizer.StormDataRequest:

datavisualizer.DataRequest

List of all members.

Public Member Functions

 StormDataRequest (String sChartName, DetailedOutputFileManager oManager) throws ModelException
 Constructor.
void AddGridPackageFloatData (String sGridName, int iX, int iY, int iCode, float fVal)
 This accepts a package float value.
boolean WantAnyGridPackageFloats ()
 This wants package floats.
void AddGridPackageFloatDataMemberCode (String sGridName, String sLabel, int iCode)
 Accepts a grid package float data member code for future reference when passed float data members.

Protected Member Functions

void WriteChartDataToFile (java.io.FileWriter jOut) throws java.io.IOException
 Writes the table's data to tab-delimited text.
JPanel CreateTable (DetailedOutputLegend oLegend)
 Turns the accumulated data into a table for viewing.

Package Functions

ModelInternalFrame DrawChart (Legend oLegend, String sChartTitle) throws ModelException
 Creates a table of the results that have been collected.
void UpdateChart (Legend oLegend) throws javawrapper.ModelException
 Does nothing unless the number of timesteps is different, in which case the table is recreated.
void ClearData () throws javawrapper.ModelException
 Does nothing, because this table doesn't operate on the detailed output file timescale.

Private Attributes

String[][] mp_sTable
 The data that will be appearing in the table - this allows us to have a copy saved for file saving etc.
Vector< Vector< Vector< Float > > > mp_oData
 Place for storing storm data as it comes in, number of X cells by number of Y cells.
String[] mp_sColHeaders
String m_sThisGrid
 Name of the grid from which the data will be collected.
int m_iNumTimesteps = -1
 The total number of timesteps.
int m_i1DmgIndexCode
 Code for "1dmg_index" package float data member.


Detailed Description

Produces a table of storm results.

A storm table requires the detailed output file to have package data saved from the "Storm Results" grid. The table has four columns: timestep, num storms, avg severity of most severe storm, avg severity of least severe storm.

This does all timesteps at once.

Copyright: Copyright (c) Charles D. Canham 2007 Company: Institute of Ecosystem Studies

Author:
Lora E. Murphy
Version:
1.0

Edit history:
------------------
June 4, 2007: Created (LEM)
February 4, 2008: Updated to conform to Java 6 compliance (LEM)

Constructor & Destructor Documentation

datavisualizer.StormDataRequest.StormDataRequest ( String  sChartName,
DetailedOutputFileManager  oManager 
) throws ModelException

Constructor.

Parameters:
sChartName Name of the chart
oManager Detailed output file manager
Exceptions:
ModelException not really, but I have to declare this.


Member Function Documentation

void datavisualizer.StormDataRequest.WriteChartDataToFile ( java.io.FileWriter  jOut  )  throws java.io.IOException [protected, virtual]

Writes the table's data to tab-delimited text.

Parameters:
jOut java.io.FileWriter The file to write to.
Exceptions:
java.io.IOException if there's a problem writing the file.

Implements datavisualizer.DataRequest.

void datavisualizer.StormDataRequest.AddGridPackageFloatData ( String  sGridName,
int  iX,
int  iY,
int  iCode,
float  fVal 
)

This accepts a package float value.

It figures out what it is, then adds it to the appropriate location.

Parameters:
sGridName Name of the grid for this data
iX X number of the cell from which this value came
iY Y number of the cell from which this value came
iCode Data member code of this value.
fVal Value.

Reimplemented from datavisualizer.DataRequest.

boolean datavisualizer.StormDataRequest.WantAnyGridPackageFloats (  ) 

This wants package floats.

Returns:
True.

Reimplemented from datavisualizer.DataRequest.

void datavisualizer.StormDataRequest.AddGridPackageFloatDataMemberCode ( String  sGridName,
String  sLabel,
int  iCode 
)

Accepts a grid package float data member code for future reference when passed float data members.

Parameters:
sGridName Name of the grid
sLabel The label of the data member.
iCode The data member code.

Reimplemented from datavisualizer.DataRequest.

ModelInternalFrame datavisualizer.StormDataRequest.DrawChart ( Legend  oLegend,
String  sChartTitle 
) throws ModelException [package, virtual]

Creates a table of the results that have been collected.

Parameters:
oLegend The species legend.
sChartTitle The chart title.
Returns:
A JInternalFrame with the table present in it.
Exceptions:
datavisualizer.ModelException 
Edit history:
------------------
March 20, 2006: Created (LEM)

Implements datavisualizer.DataRequest.

void datavisualizer.StormDataRequest.UpdateChart ( Legend  oLegend  )  throws javawrapper.ModelException [package, virtual]

Does nothing unless the number of timesteps is different, in which case the table is recreated.

This chart does not respond to regular chart update events, since it already shows data for all timesteps.

Parameters:
oLegend Legend The legend for this chart.
Exceptions:
ModelException Won't be thrown.

Implements datavisualizer.DataRequest.

JPanel datavisualizer.StormDataRequest.CreateTable ( DetailedOutputLegend  oLegend  )  [protected]

Turns the accumulated data into a table for viewing.

Returns:
JPanel The panel containing the table.

void datavisualizer.StormDataRequest.ClearData (  )  throws javawrapper.ModelException [package, virtual]

Does nothing, because this table doesn't operate on the detailed output file timescale.

Exceptions:
ModelException Won't throw it.

Implements datavisualizer.DataRequest.


Member Data Documentation

The data that will be appearing in the table - this allows us to have a copy saved for file saving etc.

Vector<Vector<Vector<Float> > > datavisualizer.StormDataRequest.mp_oData [private]

Place for storing storm data as it comes in, number of X cells by number of Y cells.

Initial value:

 {"Timestep", "Num storms", 
                "Mean of most severe", "Mean of least severe"}

Name of the grid from which the data will be collected.

The total number of timesteps.

We keep track of this so we know if something has changed (as in real-time data visualization) so we can update appropriately.

Code for "1dmg_index" package float data member.


The documentation for this class was generated from the following file:

Generated on Wed Oct 28 14:01:18 2009 for SORTIE Java Interface by  doxygen 1.5.6