javawrapper.ManageTreeMap Class Reference

Allows management of tree maps. More...

Inherits javax::swing::JDialog, and java::awt::event::ActionListener.

List of all members.

Public Member Functions

 ManageTreeMap (JFrame jParent, TreePopulation oPop) throws ModelException
 Constructor.
void actionPerformed (ActionEvent e)
 Controls actions for this window.

Protected Member Functions

void RestoreOriginalView ()
 Restores the original view of the tree map with the scale at which it was first displayed.
void Scroll (int iDirection) throws ModelException
 Scrolls the view 10% in the specified direction.
void WriteTreeMap () throws ModelException
 Writes the tree map trees to a tab-delimited text file.
void RefreshChart () throws ModelException
 Refreshes the chart to show the data currently held in the dataset.
JPanel MakeTreeLegendPanel ()
 Creates a tree legend panel.

Protected Attributes

JPanel m_jChartPanel = new JPanel()
 Tree dataset.
Color[] mp_jSpeciesColors
 Colors for each species.
TreePopulation m_oPop
 TreePopulation object that data changes will be communicated to.
JButton m_jClearTreeMap
 Button for clearing tree map trees.
JButton m_jWriteTreeMap
 Button for writing a tree map as tab-delimited text.

Static Package Attributes

static final long serialVersionUID = 1

Private Member Functions

DefaultXYZDataset CreateTreeMapDataset () throws ModelException
 Creates the tree map dataset.

Private Attributes

JTextField m_jDBHScale = new JTextField("")
 Field displaying the DBH scale factor.
JTextField m_jMinDbh = new JTextField("")
 Field displaying the minimum DBH.
String m_sHelpID = "windows.edit_manage_tree_maps_window"
 Help ID string.
float m_fMinDbh
 Minimum dbh to draw.
float m_fDBHScale = (float) 1.0
 DBH scale factor.
float m_fXPlotLength
 X plot length in meters.
float m_fYPlotLength
 Y plot length in meters.

Static Private Attributes

static final int LEFT = 1
 Scrolling left.
static final int RIGHT = 2
 Scrolling right.
static final int UP = 3
 Scrolling up.
static final int DOWN = 4
 Scrolling down.


Detailed Description

Allows management of tree maps.

Author:
Lora Murphy
Edit history:
------------------
February 27, 2008: Created by breaking off of a single tree setup window (LEM)
March 5, 2008: Added tree map display (LEM)

Constructor & Destructor Documentation

javawrapper.ManageTreeMap.ManageTreeMap ( JFrame  jParent,
TreePopulation  oPop 
) throws ModelException

Constructor.

Constructs and displays the GUI.

Parameters:
jParent Parent window in which to display this dialog.
oPop TreePopulation object.


Member Function Documentation

void javawrapper.ManageTreeMap.actionPerformed ( ActionEvent  e  ) 

Controls actions for this window.

Parameters:
e ActionEvent.

void javawrapper.ManageTreeMap.RestoreOriginalView (  )  [protected]

Restores the original view of the tree map with the scale at which it was first displayed.

void javawrapper.ManageTreeMap.Scroll ( int  iDirection  )  throws ModelException [protected]

Scrolls the view 10% in the specified direction.

If the view is full-size nothing happens. If the view is already scrolled all the way over in the specified direction nothing happens.

Parameters:
iDirection int Direction in which to scroll.

void javawrapper.ManageTreeMap.WriteTreeMap (  )  throws ModelException [protected]

Writes the tree map trees to a tab-delimited text file.

It first displays to the user a dialog for specifying the file name. It then organizes a 2-D array of strings for all possible tree data members that have been defined. Each tree contributes its applicable values to the table. Then the table is written out.

Exceptions:
ModelException if the file cannot be written.

void javawrapper.ManageTreeMap.RefreshChart (  )  throws ModelException [protected]

Refreshes the chart to show the data currently held in the dataset.

Exceptions:
ModelException if the chart cannot be created.

DefaultXYZDataset javawrapper.ManageTreeMap.CreateTreeMapDataset (  )  throws ModelException [private]

Creates the tree map dataset.

JPanel javawrapper.ManageTreeMap.MakeTreeLegendPanel (  )  [protected]

Creates a tree legend panel.

Returns:
JPanel Panel with tree legend on it.


Member Data Documentation

final long javawrapper.ManageTreeMap.serialVersionUID = 1 [static, package]

JPanel javawrapper.ManageTreeMap.m_jChartPanel = new JPanel() [protected]

Tree dataset.

Panel container for the chart

Colors for each species.

TreePopulation object that data changes will be communicated to.

Button for clearing tree map trees.

Button for writing a tree map as tab-delimited text.

JTextField javawrapper.ManageTreeMap.m_jDBHScale = new JTextField("") [private]

Field displaying the DBH scale factor.

JTextField javawrapper.ManageTreeMap.m_jMinDbh = new JTextField("") [private]

Field displaying the minimum DBH.

String javawrapper.ManageTreeMap.m_sHelpID = "windows.edit_manage_tree_maps_window" [private]

Help ID string.

Minimum dbh to draw.

float javawrapper.ManageTreeMap.m_fDBHScale = (float) 1.0 [private]

DBH scale factor.

X plot length in meters.

Y plot length in meters.

final int javawrapper.ManageTreeMap.LEFT = 1 [static, private]

Scrolling left.

final int javawrapper.ManageTreeMap.RIGHT = 2 [static, private]

Scrolling right.

final int javawrapper.ManageTreeMap.UP = 3 [static, private]

Scrolling up.

final int javawrapper.ManageTreeMap.DOWN = 4 [static, private]

Scrolling down.


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

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