Public Member Functions | |
ModelFlowSetup (JFrame oParent, GUIManager oManager) | |
Constructor. | |
void | actionPerformed (ActionEvent e) |
Controls actions for this window. | |
void | valueChanged (javax.swing.event.TreeSelectionEvent e) |
Detects user clicks on the tree. | |
Protected Member Functions | |
void | SetBehaviorList (int iSpecies, int iType, String[] p_sBehaviors) throws ModelException |
Sets the behavior list for a species/type combo in the temporary list held in this object. | |
void | CreateGUI () throws ModelException |
Draws the window displaying the data as a tree. | |
Vector | GetBehaviorList (int iSpecies, int iType) throws ModelException |
Gets a vector of behavior names for a type/species combo from our temporary behavior copy set. | |
Vector | GetBehaviorList (String sGridName) throws ModelException |
Gets the enabled behaviors that apply to a grid from our temporary behavior copy set. | |
void | BuildTypeFirstTree (DefaultMutableTreeNode jRoot) throws ModelException |
Builds the tree displayed in the window with data first; for trees, the branch levels are type, then species, then behavior list. | |
void | BuildSpeciesFirstTree (DefaultMutableTreeNode jRoot) throws ModelException |
Builds the tree displayed in the window with data first; for trees, the branch levels are species, then type, then behavior list. | |
void | BuildBehaviorFirstTree (DefaultMutableTreeNode jRoot) throws ModelException |
Builds a tree where the first level is behavior; the second is data, with trees being type first, then species. | |
DefaultMutableTreeNode | BuildGridNode () throws ModelException |
Builds a node for Grid data. | |
void | BuildTree () throws ModelException |
Builds the tree displayed in the window. | |
void | AssignData () throws ModelException |
Assigns the changes made in this dialog back to the behavior groups. | |
void | UpdateBehaviorChoices (JComboBox jBehaviorGroupBox, DefaultListModel jIndividualBehaviorListModel) |
A common function for those dialogs which contain a list of behavior groups, a choice upon which populates individual behaviors into another list. | |
String[] | GetBehaviorAddName (JList jBehaviorList, DefaultListModel jBehaviorListModel, DefaultListModel jListToAddTo) |
Common function for those dialogs which add a behavior to a list. | |
Protected Attributes | |
GUIManager | m_oManager |
GUIManager object. | |
JTree | m_jTree = null |
Tree showing flow. | |
DefaultTreeModel | m_jTreeModel |
Data model of tree showing flow. | |
TreePopulation | m_oPop |
TreePopulation object. | |
String[] | mp_sBehaviorGroupNames = null |
List of behavior groups. | |
String[] | mp_sGridNames = null |
List of grid names. | |
Behavior[][] | mp_oBehaviors |
Our copy of the Behaviors. | |
Dimension | m_oMaxDimension |
Max dimensions of the main program flow dialog. | |
final int | BEHAVIOR_FIRST = 0 |
Flag indicating that the tree should display behaviors at the highest level. | |
final int | TYPE_FIRST = 1 |
Flag indicating that the tree should display data at the highest level, and for trees, type at a higher level than species. | |
final int | SPECIES_FIRST = 2 |
Flag indicating that the tree should display data at the highest level, and for trees, species at a higher level than type. | |
int | m_iMode = TYPE_FIRST |
Mode by which the tree should be built - will be one of the finals below. | |
Private Attributes | |
String | m_sHelpID = "windows.model_flow_window" |
Classes | |
class | BehaviorIndexer |
Class which packages individual behavior names with an index number. More... | |
class | ComboDisplay |
Combines a text description of species/type combos with the actual data, for display in lists. More... | |
class | DisplayBehaviorComboEdit |
Displays an edit window for editing the tree species/type combos to which a single behavior applies. More... | |
class | DisplayBehaviorEdit |
Displays the edit window for editing behavior order. More... | |
class | DisplayComboEdit |
Displays the edit window for editing behavior flow for a tree species/ type combo. More... | |
class | ListRenderer |
Provides multi-line text wrapping to our list boxes. More... | |
class | TreeNodeInfo |
Objects set in tree nodes to give information about what to do when the user clicks a node. More... |
Copyright: Copyright (c) 2003 Charles D. Canham
Company: Institute of Ecosystem Studies
|
Constructor.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Controls actions for this window.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Assigns the changes made in this dialog back to the behavior groups. First the behavior settings are validated, and then they are copied back in order to the behavior groups.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Builds a tree where the first level is behavior; the second is data, with trees being type first, then species.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Builds a node for Grid data. First level is grid name, second level is behavior.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Builds the tree displayed in the window with data first; for trees, the branch levels are species, then type, then behavior list.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Builds the tree displayed in the window. If it already exists, it will be torn down and recreated.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Builds the tree displayed in the window with data first; for trees, the branch levels are type, then species, then behavior list.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Draws the window displaying the data as a tree.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Common function for those dialogs which add a behavior to a list. This extracts chosen behaviors' names, returning null if no behavior should be added. THIS DOES NOT ACTUALLY ADD THE NAME TO THE TARGET LIST. The behavior name is left null if there is no index selected, or if no selection is eligible. Selections are ineligible if the behavior name starts with "--", or if the behavior is already on the target list.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Gets the enabled behaviors that apply to a grid from our temporary behavior copy set.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Gets a vector of behavior names for a type/species combo from our temporary behavior copy set.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Sets the behavior list for a species/type combo in the temporary list held in this object. This does NOT make the changes in the official list held in the GUIManager object. The GUI is updated to reflect changes.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
A common function for those dialogs which contain a list of behavior groups, a choice upon which populates individual behaviors into another list. If there is no choice, nothing happens. If the behavior group is "Planting" or "Output", instead of behavior choices the string "--Use this behavior's own dialog" will be displayed.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Detects user clicks on the tree.
Edit history: ------------------ April 28, 2004: Submitted in beta version (LEM) |
|
Our copy of the Behaviors. The first index is behavior group number; the second is a list of all Behaviors for that group, in order. These are clones, so we can mess with them here, and then load the data back when we're done. |