edu.iastate.metnet.birdseyeview
Class LoadController

java.lang.Object
  extended by edu.iastate.metnet.birdseyeview.LoadController

public class LoadController
extends java.lang.Object

The LoadController Class handles the loading of the experimental data for Bird's Eye View. Basically, an instance of this class will open a window from which enables users to load new data files.

Author:
Matt Studham Created Mar 16, 2005, Lifeng Zhang Created Sep 16, 2006

Field Summary
static java.lang.String ExperimentalData
           
static java.lang.String ExperimentNames
           
static java.lang.String IntegrationData
           
static java.lang.String ProbeNames
           
 
Constructor Summary
LoadController(BirdsEyeView bev)
          Constructor.
 
Method Summary
 void cancelLoad()
          This method resets all the temporary variables and closes the load window.
 void commitLoad()
          This method finalizes the loading of the new data for the Bird's Eye View.
 java.lang.String getExperimentName()
          Added by Mohammed Alabsi - April 13th, 2006 Method to get the name of current experiment.
 java.util.ArrayList<java.lang.String> getExperiments()
          Added by Mohammed Alabsi - April 13th, 2006 Method to get list of experiments names
 java.util.Hashtable getExperimentsTable()
          Added by Mohammed Alabsi - April 13th, 2006 Returned data from all experiments
 java.util.ArrayList<java.lang.String> getProbeNames()
          Added by Mohammed Alabsi - April 13th, 2006 Method to get list of probnames
 java.util.ArrayList<java.lang.Double> getVariances()
          Added by Mohammed Alabsi - April 13th, 2006 Method to get the variances values
 boolean isImported()
           
 void load()
          This method opens the load window.
 void loadAllData()
          Added by Mohammed Alabsi - April 13th, 2006 Method loads all the data in file to experiment table.
 void loadData(java.lang.String type, java.lang.String filePath)
          This method loads the data of the given type from the given file path.
 void loadExperiment(int experimentIndex)
          This method loads the variances for the given experiment.
 void loadImportedData(java.lang.String experimentName, java.util.ArrayList experiments, java.util.ArrayList probeNames, java.util.ArrayList variances, java.util.Hashtable data)
          Method added by Mohammed Alabsi - April 13th, 2006 Method load the data recieved from a MetNet application and loads it into BEV
 void setExperiment(java.lang.String eName)
          This method sets the name of the experiment which will be analyzed.
 void setExperimentsTable(java.util.Hashtable experimentsTable)
           
 void setImported(boolean imported)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ProbeNames

public static final java.lang.String ProbeNames
See Also:
Constant Field Values

ExperimentNames

public static final java.lang.String ExperimentNames
See Also:
Constant Field Values

ExperimentalData

public static final java.lang.String ExperimentalData
See Also:
Constant Field Values

IntegrationData

public static final java.lang.String IntegrationData
See Also:
Constant Field Values
Constructor Detail

LoadController

public LoadController(BirdsEyeView bev)
Constructor. Initialize everything.

Parameters:
bev - BirdsEyeView controller object
Method Detail

load

public void load()
This method opens the load window.


setExperiment

public void setExperiment(java.lang.String eName)
This method sets the name of the experiment which will be analyzed. This change will not really be saved unless the commit() method is called.

Parameters:
eName - String name of experiment

loadData

public void loadData(java.lang.String type,
                     java.lang.String filePath)
This method loads the data of the given type from the given file path. The data isn't really loaded until the commit() method is called.

Parameters:
type - Type of data
filePath - Fully qualified file name

commitLoad

public void commitLoad()
This method finalizes the loading of the new data for the Bird's Eye View. It also closes the load window. Remember, there may be null variance objects.


loadAllData

public void loadAllData()
                 throws FieldNotFoundException,
                        java.lang.Exception
Added by Mohammed Alabsi - April 13th, 2006 Method loads all the data in file to experiment table.

Throws:
FieldNotFoundException
java.lang.Exception

cancelLoad

public void cancelLoad()
This method resets all the temporary variables and closes the load window.


loadExperiment

public void loadExperiment(int experimentIndex)
This method loads the variances for the given experiment.

Parameters:
experimentIndex - Index in the list of experiments

loadImportedData

public void loadImportedData(java.lang.String experimentName,
                             java.util.ArrayList experiments,
                             java.util.ArrayList probeNames,
                             java.util.ArrayList variances,
                             java.util.Hashtable data)
Method added by Mohammed Alabsi - April 13th, 2006 Method load the data recieved from a MetNet application and loads it into BEV

Parameters:
experimentName -
experiments -
probeNames -
variances -
data -

getExperimentName

public java.lang.String getExperimentName()
Added by Mohammed Alabsi - April 13th, 2006 Method to get the name of current experiment.

Returns:
attribute experimentName

getExperiments

public java.util.ArrayList<java.lang.String> getExperiments()
Added by Mohammed Alabsi - April 13th, 2006 Method to get list of experiments names

Returns:
attribute experiments

getProbeNames

public java.util.ArrayList<java.lang.String> getProbeNames()
Added by Mohammed Alabsi - April 13th, 2006 Method to get list of probnames

Returns:
attribute probeNames

getVariances

public java.util.ArrayList<java.lang.Double> getVariances()
Added by Mohammed Alabsi - April 13th, 2006 Method to get the variances values

Returns:
variances

getExperimentsTable

public java.util.Hashtable getExperimentsTable()
Added by Mohammed Alabsi - April 13th, 2006 Returned data from all experiments

Returns:

setExperimentsTable

public void setExperimentsTable(java.util.Hashtable experimentsTable)
Parameters:
experimentsTable - The experimentsTable to set.

isImported

public boolean isImported()
Returns:
Returns the imported.

setImported

public void setImported(boolean imported)
Parameters:
imported - The imported to set.