Class StageNames

java.lang.Object
  |
  +--StageNames

class StageNames
extends java.lang.Object

The class sets up staging names for building menus and sample labels. These sample labels are used in variousplots and reports. The stage names reflects the structure of SamplesDB.txt:Menu_Stage_Name entries which are saved in menuNames[] and are used later to build the Samples menu trees. We build the mae.hps.topSubMenuNames[] list from these entries if any. The staging data is contained in the SamplesDB.txt Table and the snXXXX[sample#] results are in the mae.snXXX[] arrays.

The use of the PopupHPChooser is the preferred method as it is easier to navigate than the menus.

This work was produced by Peter Lemkin of the National Cancer Institute, an agency of the United States Government. As a work of the United States Government there is no associated copyright. It is offered as open source software under the Mozilla Public License (version 1.1) subject to the limitations noted in the accompanying LEGAL file. This notice must be included with the code. The MAExplorer Mozilla and Legal files are available on http://maexplorer.sourceforge.net/.

Version:
$Date: 2002/12/11 17:23:27 $ $Revision: $
Author:
P. Lemkin (NCI), G. Thornwall (SAIC), NCI-Frederick, Frederick, MD
See Also:
MAExplorer Home

Field Summary
(package private)  StageNames[] HPmnuEntry
          list of menus that the entry belongs to
(package private)  int hpNbr
          idx of mae.snHPNames[]
(package private)  int menuJ
          index for menuNames[]
(package private)  java.lang.String[] menuNames
          List unique menu name entries for various entities in Samples tbl
(package private)  int nHPmnuEntries
          # of menu entries
(package private)  int nmenuNames
          # unique menu name entries in Samples tbl
(package private)  int nprobeNames
          # unique probe name entries in Samples tbl
(package private)  int nsourceNames
          # unique source name entries in Samples tbl
(package private)  int nstageNames
          # unique stage name entries in Samples tbl
(package private)  int nstrainNames
          # unique strain name entries in Samples tbl
(package private)  int probeJ
          index for probeNames[]
(package private)  java.lang.String[] probeNames
          List unique probe name entries for various entities in Samples tbl
(package private)  int sampleDBrow
          row of membrane table
(package private)  int sourceJ
          index for sourceNames[]
(package private)  java.lang.String[] sourceNames
          List unique source name entries for various entities in Samples tbl
(package private)  int stageJ
          index for stageNames[]
(package private)  java.lang.String stageLabel
          itemLabel to be used in menu
(package private)  java.lang.String[] stageNames
          List unique stage name entries for various entities in Samples tbl
(package private)  int strainJ
          index for strainNames[]
(package private)  java.lang.String[] strainNames
          List unique strain name entries for various entities in Samples tbl
(package private)  int subMenuNbr
          submenu # correspndg to Source
 
Constructor Summary
(package private) StageNames(int subMenuNbr, int hpNbr, int sampleDBrow, int menuJ, int sourceJ, int strainJ, int stageJ, int probeJ, java.lang.String stageLabel)
          StageNames() - constructor with data
(package private) StageNames(MAExplorer mae)
          StageNames() - initial global constructor with no data
 
Method Summary
(package private)  boolean getMenuTreeFromSamplesTable(MAExplorer mae)
          getMenuTreeFromSamplesTable() - build tree from Samples.txt Table
private  void sortMenuEntriesByStage(StageNames[] data, int lth)
          sortMenuEntriesByStage() - sort HPmnuEntry[] by Stage.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

menuNames

java.lang.String[] menuNames
List unique menu name entries for various entities in Samples tbl

sourceNames

java.lang.String[] sourceNames
List unique source name entries for various entities in Samples tbl

strainNames

java.lang.String[] strainNames
List unique strain name entries for various entities in Samples tbl

stageNames

java.lang.String[] stageNames
List unique stage name entries for various entities in Samples tbl

probeNames

java.lang.String[] probeNames
List unique probe name entries for various entities in Samples tbl

nmenuNames

int nmenuNames
# unique menu name entries in Samples tbl

nsourceNames

int nsourceNames
# unique source name entries in Samples tbl

nstrainNames

int nstrainNames
# unique strain name entries in Samples tbl

nstageNames

int nstageNames
# unique stage name entries in Samples tbl

nprobeNames

int nprobeNames
# unique probe name entries in Samples tbl

HPmnuEntry

StageNames[] HPmnuEntry
list of menus that the entry belongs to

nHPmnuEntries

int nHPmnuEntries
# of menu entries

subMenuNbr

int subMenuNbr
submenu # correspndg to Source

hpNbr

int hpNbr
idx of mae.snHPNames[]

sampleDBrow

int sampleDBrow
row of membrane table

menuJ

int menuJ
index for menuNames[]

sourceJ

int sourceJ
index for sourceNames[]

strainJ

int strainJ
index for strainNames[]

stageJ

int stageJ
index for stageNames[]

probeJ

int probeJ
index for probeNames[]

stageLabel

java.lang.String stageLabel
itemLabel to be used in menu
Constructor Detail

StageNames

StageNames(MAExplorer mae)
StageNames() - initial global constructor with no data
Parameters:
mae - is MAExplorer instance

StageNames

StageNames(int subMenuNbr,
           int hpNbr,
           int sampleDBrow,
           int menuJ,
           int sourceJ,
           int strainJ,
           int stageJ,
           int probeJ,
           java.lang.String stageLabel)
StageNames() - constructor with data
Parameters:
subMenuNbr - is the submenu # correspndg to Source
hpNbris - the idx of mae.snHPNames[]
sampleDBrow - is the row of sample DB table
menuJ - is the index for menuNames[]
sourceJ - is the index for sourceNames[]
strainJ - is the index for strainNames[]
stageJ - is the index for stageNames[]
probeJ - is the index for probeNames[]
stageLabel - is the item label for menu
Method Detail

getMenuTreeFromSamplesTable

boolean getMenuTreeFromSamplesTable(MAExplorer mae)
getMenuTreeFromSamplesTable() - build tree from Samples.txt Table
 The Pull-down menus should look like:
  Menu_Stage_Name
    Source
      Strain
        Stage
Parameters:
mae - is MAExplorer instance
Returns:
true if succeed
See Also:
SamplesTable.getUniqueTableFieldData(int), StageNames, Util.findIndexForKey(java.lang.String[], java.lang.String), sortMenuEntriesByStage(StageNames[], int)

sortMenuEntriesByStage

private void sortMenuEntriesByStage(StageNames[] data,
                                    int lth)
sortMenuEntriesByStage() - sort HPmnuEntry[] by Stage.
Parameters:
data - is list of stagenames