O2Plib.db.CSD
Class CSDacc

java.lang.Object
  extended by O2Plib.db.CSD.CSDglb
      extended by O2Plib.db.CSD.CSDacc

public class CSDacc
extends CSDglb

Class CSDacc contains the accession database information for the Composite Samples Database (CSD).


 This file is derived from Open2Dprot, MAExplorer and GELLAB-II code.

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 Open2Dprot Mozilla and Legal files are available on http://Open2Dprot.sourceforge.net/.

Version:
$Date: 2005/12/09 15:04:26 $ $Revision: 1.10 $
Author:
P. Lemkin, NCI-Frederick, Frederick, MD, 21702

Field Summary
static DbAccession acc
          Accession database if it exists
 java.lang.String accFile
          Accession database file if it exists
 java.lang.String accFilePath
          Full Accession database file if it exists
 int[] idxSampleList
          index values of the samples [0:nSamples-1]
 int maxFields
          maximum # of MIAPE accession fields used to define the study string, Size of miapeStudyFields[] (optional).
 int maxSamples
          maximum # of samples in accession database (optional).
 java.lang.String[][] miapeStudyData
          [0:nSamples-1][0:nMiapeFields-1] A short version of a samples's accession info is assembled from MIAPE/accession fields specified by miapeStudyFields[].
 java.lang.String[] miapeStudyFields
          [0:nMiapeFields-1] list of names of MIAPE accession fields used to define the study string
 int nMiapeFields
          # of MIAPE accession fields used to define the study string, Size of miapeStudyFields[].
 int nSamples
          # samples
 java.lang.String[] sampleNames
          names of the samples [0:nSamples-1]
static java.lang.String VERSION
          Version for this module
 
Fields inherited from class O2Plib.db.CSD.CSDglb
allSetSamples, AP, batchDir, BF_IS_LMS_SPOT, BF_ISVALIDSPOT, cacheDir, cdbIsOpenFlag, condListDB, CONSOLE_FLAG, CP, CSD_DBTYPE_CACHE, CSD_DBTYPE_RDBMS, CSD_DBTYPE_TAB_DELIM, CSD_DBTYPE_UNKNOWN, CSD_DBTYPE_XML, csdAcc, csdCache, csdCacheFile, csdDatabaseFile, csdFormatMode, csdIO, csdLMS, csdName, csdRdbmsFile, csdSizes, csdTabDelimFile, csdTotals, CSDversion, csdXMLfile, dataFiltersListDB, dateCreation, dateLastSession, dbRsample, dbSample, dbSamplesListDB, dbSPFlistsDB, dBugLMsetNbr, dBugPspotNbr, dBugRspotNbr, dBugSampleNbr, EP, epSetSamples, exprListsDB, GS, LM, MAX_NODE_SAFTY_FACTOR, mrl, nbrTimesInitialized, nCondListDB, nDataFiltersDB, needToSaveCSDdataFlag, NEVER, nExprListsDB, nOclDB, nodeSaftyFactor, normListDB, nRmapsDB, nRspotListsDB, nSamplesDB, nSPFfilesUsedDB, nSPFlistsDB, oclListDB, oclNameDB, PP, ppxDir, projDir, rdbmsDir, rMapsListDB, RSAMPLE, rspotListsDB, SAMPLE, sampleNamesDB, sampleNamesUsedDB, SP, tmpDir, US, useInternalDTDflag, wrkAnotation, wrkCalib, wrkERspot, wrkExpr, wrkSetSamples, xmlDir, xSetSamples, ySetSamples
 
Constructor Summary
CSDacc()
          CSDacc() - Constructor for new CSDacc.
 
Method Summary
 java.lang.String[][] getStudyDataForAllSamples()
          getStudyDataForAllSamples() - get the accession database study data for all samples
 java.lang.String[] getStudyDataForSample(int sampleIdx)
          getStudyDataForSample() - get the accession database study data for a particular sample
 java.lang.String[] getStudyFields()
          getStudyFields() - get the accession database study fields
static java.lang.String getTabDelimitedFields()
          getTabDelimitedFields() - get a string representation of the tab-delimited data fields
 void setAccessionDB(java.lang.String accFile, java.lang.String accFilePath, DbAccession acc)
          setAccessionDB() - assign the accession DB
 boolean setStudyFields(java.lang.String[] studyFields)
          setStudyFields() - set the accession database study fields.
 java.lang.String toString()
          toString() - get a pretty-print string representation of this instance
 java.lang.String toTabDelimitedData()
          toTabDelimitedData() - get a string representation of this instance as tab-delimited data values
 java.lang.String toXML()
          toXML() - get a string representation of this instance as XML
 
Methods inherited from class O2Plib.db.CSD.CSDglb
initGlb
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VERSION

public static final java.lang.String VERSION
Version for this module

See Also:
Constant Field Values

acc

public static DbAccession acc
Accession database if it exists


accFile

public java.lang.String accFile
Accession database file if it exists


accFilePath

public java.lang.String accFilePath
Full Accession database file if it exists


nSamples

public int nSamples
# samples


maxSamples

public int maxSamples
maximum # of samples in accession database (optional).


sampleNames

public java.lang.String[] sampleNames
names of the samples [0:nSamples-1]


idxSampleList

public int[] idxSampleList
index values of the samples [0:nSamples-1]


miapeStudyFields

public java.lang.String[] miapeStudyFields
[0:nMiapeFields-1] list of names of MIAPE accession fields used to define the study string


miapeStudyData

public java.lang.String[][] miapeStudyData
[0:nSamples-1][0:nMiapeFields-1] A short version of a samples's accession info is assembled from MIAPE/accession fields specified by miapeStudyFields[].


nMiapeFields

public int nMiapeFields
# of MIAPE accession fields used to define the study string, Size of miapeStudyFields[].


maxFields

public int maxFields
maximum # of MIAPE accession fields used to define the study string, Size of miapeStudyFields[] (optional).

Constructor Detail

CSDacc

public CSDacc()
CSDacc() - Constructor for new CSDacc.

Method Detail

setAccessionDB

public void setAccessionDB(java.lang.String accFile,
                           java.lang.String accFilePath,
                           DbAccession acc)
setAccessionDB() - assign the accession DB

Parameters:
accFile - is accession database file
accFilePath - is full path accession database file
acc - is the accession database instance

getStudyFields

public java.lang.String[] getStudyFields()
getStudyFields() - get the accession database study fields

Returns:
study fields miapeStudyFields[0:nMiapeFields-1], null if none

setStudyFields

public boolean setStudyFields(java.lang.String[] studyFields)
setStudyFields() - set the accession database study fields. If the studyFields.length is different from current miapeStudyFields.length, then fail since the existing data will be the wrong matrix shape. Note: be aware this could put the wrong field names for the corresponding data.

Parameters:
study - fields
Returns:
true if succeed

getStudyDataForAllSamples

public java.lang.String[][] getStudyDataForAllSamples()
getStudyDataForAllSamples() - get the accession database study data for all samples

Returns:
study data miapeStudyData[0:nSamples-1][0:nMiapeFields-1], null if none

getStudyDataForSample

public java.lang.String[] getStudyDataForSample(int sampleIdx)
getStudyDataForSample() - get the accession database study data for a particular sample

Parameters:
sampleIdx - is the sample to use
Returns:
study data miapeStudyData[sampleIdx], null if none

toString

public java.lang.String toString()
toString() - get a pretty-print string representation of this instance

Overrides:
toString in class java.lang.Object
Returns:
string representation of this instance

getTabDelimitedFields

public static java.lang.String getTabDelimitedFields()
getTabDelimitedFields() - get a string representation of the tab-delimited data fields

Returns:
string representation of this instance, no "\n"

toTabDelimitedData

public java.lang.String toTabDelimitedData()
toTabDelimitedData() - get a string representation of this instance as tab-delimited data values

Returns:
string representation of this instance, no "\n"

toXML

public java.lang.String toXML()
toXML() - get a string representation of this instance as XML

Returns:
string representation of this instance