edu.jhu.tmaj.servlet.request.impl
Class ScoredImageDetailsRequest

java.lang.Object
  extended by edu.jhu.tmaj.servlet.request.BaseRequest
      extended by edu.jhu.tmaj.servlet.request.impl.DetailsRequest
          extended by edu.jhu.tmaj.servlet.request.impl.ScoredImageDetailsRequest
All Implemented Interfaces:
CommandRequest, java.io.Serializable

public final class ScoredImageDetailsRequest
extends DetailsRequest
implements java.io.Serializable

Retrieves information about every x and y position from a session (a scored array) and puts it into a table format (List of Lists). Each row represents a position (example x=2,y=5)

See Also:
Serialized Form

Field Summary
static TableField ARRAYBLOCKID_FIELD
           
static TableField ARRAYIMAGEID_FIELD
           
static TableField HAS_DRAWINGS_FIELD
           
(package private) static org.slf4j.Logger logger
           
static TableField SCORED_IMAGE_ID_FIELD
           
static TableField SCOREDIMAGES_INPUT_LOG_FIELD
           
static TableField SCOREDIMAGES_NOTES_FIELD
           
static TableField SCOREDIMAGES_TISSUETYPEID_FIELD
           
static TableField SESSIONID_FIELD
           
static TableField SPECIMEN_TYPE_FIELD
           
static TableField SPECIMENID_FIELD
           
static TableField TD_TYPE_FIELD
           
static TableField TISSUEDIAGNOSISID_FIELD
           
static TableField X_FIELD
           
static TableField Y_FIELD
           
 
Fields inherited from class edu.jhu.tmaj.servlet.request.impl.DetailsRequest
userBean
 
Fields inherited from class edu.jhu.tmaj.servlet.request.BaseRequest
password, username
 
Constructor Summary
ScoredImageDetailsRequest(int[] sessions, DynamicMetaData specimensDynamicMetaData, DynamicMetaData tissueDiagnosisDynamicMetaData, DynamicMetaData scoredImagesDynamicMetaData, java.util.Map<java.lang.Integer,LookupRecord> specimenTypeID_specimenTypeBean, java.util.Map<java.lang.Integer,LookupRecord> tissueTypeID_tissueTypeBean)
          Since this is executed on the server side, the request must pass in the cached MetaData from MyBeans
 
Method Summary
protected  void doMetaDataQueries()
          Add Dynamic data from the Specimens,TissueDiagnosis, and ArrayImage sections
protected  java.lang.String getMainQuerySQL()
          The ScoredImages table can not be included in this query, since some of the spots on the ArraySlide may have not been scored yet, and thus not record in the ScoredImages table would exist.
protected  ExpandingMap getNewExpandingMap()
           
protected  StaticFields getStaticFields()
          Returns fields and their table-names from non-dynamic tables.
protected  void lookupStaticValuesInRecord(java.util.Map record)
          Lookups the TissueType,SpecimenType, and BlockFixationID from their respective tables
protected  void renameFields(java.util.List<TableField> fieldNamesList)
           
protected  java.util.List<java.util.Map> sortListOfMaps(java.util.List<java.util.Map> listOfMaps)
          Sorts a List of Maps by the sessionid,y,x fields found in each of the Maps
 java.lang.String toString()
           
protected  void verifyUser(UserBean userBean)
          Throws an exception if the user is not allowed to make this Request
 
Methods inherited from class edu.jhu.tmaj.servlet.request.impl.DetailsRequest
doMetaDataQuery, getExpandingMap, getWarnings, lookupStaticField, processRequest
 
Methods inherited from class edu.jhu.tmaj.servlet.request.BaseRequest
executeCommand, getPassword, getUsername
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

logger

static final org.slf4j.Logger logger

SCORED_IMAGE_ID_FIELD

public static final TableField SCORED_IMAGE_ID_FIELD

SCOREDIMAGES_TISSUETYPEID_FIELD

public static final TableField SCOREDIMAGES_TISSUETYPEID_FIELD

SCOREDIMAGES_NOTES_FIELD

public static final TableField SCOREDIMAGES_NOTES_FIELD

SCOREDIMAGES_INPUT_LOG_FIELD

public static final TableField SCOREDIMAGES_INPUT_LOG_FIELD

X_FIELD

public static final TableField X_FIELD

Y_FIELD

public static final TableField Y_FIELD

SESSIONID_FIELD

public static final TableField SESSIONID_FIELD

ARRAYIMAGEID_FIELD

public static final TableField ARRAYIMAGEID_FIELD

SPECIMENID_FIELD

public static final TableField SPECIMENID_FIELD

SPECIMEN_TYPE_FIELD

public static final TableField SPECIMEN_TYPE_FIELD

TISSUEDIAGNOSISID_FIELD

public static final TableField TISSUEDIAGNOSISID_FIELD

TD_TYPE_FIELD

public static final TableField TD_TYPE_FIELD

HAS_DRAWINGS_FIELD

public static final TableField HAS_DRAWINGS_FIELD

ARRAYBLOCKID_FIELD

public static final TableField ARRAYBLOCKID_FIELD
Constructor Detail

ScoredImageDetailsRequest

public ScoredImageDetailsRequest(int[] sessions,
                                 DynamicMetaData specimensDynamicMetaData,
                                 DynamicMetaData tissueDiagnosisDynamicMetaData,
                                 DynamicMetaData scoredImagesDynamicMetaData,
                                 java.util.Map<java.lang.Integer,LookupRecord> specimenTypeID_specimenTypeBean,
                                 java.util.Map<java.lang.Integer,LookupRecord> tissueTypeID_tissueTypeBean)
Since this is executed on the server side, the request must pass in the cached MetaData from MyBeans

Method Detail

getNewExpandingMap

protected ExpandingMap getNewExpandingMap()
Specified by:
getNewExpandingMap in class DetailsRequest

verifyUser

protected void verifyUser(UserBean userBean)
                   throws java.sql.SQLException
Description copied from class: DetailsRequest
Throws an exception if the user is not allowed to make this Request

Specified by:
verifyUser in class DetailsRequest
Throws:
java.sql.SQLException

renameFields

protected void renameFields(java.util.List<TableField> fieldNamesList)
Overrides:
renameFields in class DetailsRequest

getStaticFields

protected StaticFields getStaticFields()
Description copied from class: DetailsRequest
Returns fields and their table-names from non-dynamic tables.

Specified by:
getStaticFields in class DetailsRequest

getMainQuerySQL

protected java.lang.String getMainQuerySQL()
                                    throws java.sql.SQLException
The ScoredImages table can not be included in this query, since some of the spots on the ArraySlide may have not been scored yet, and thus not record in the ScoredImages table would exist. If there is no record in the ScoredImages table, the row for that spot will not be displayed. This is why you need the ScoredImageQuery class.

Specified by:
getMainQuerySQL in class DetailsRequest
Throws:
java.sql.SQLException

lookupStaticValuesInRecord

protected void lookupStaticValuesInRecord(java.util.Map record)
Lookups the TissueType,SpecimenType, and BlockFixationID from their respective tables

Specified by:
lookupStaticValuesInRecord in class DetailsRequest

sortListOfMaps

protected java.util.List<java.util.Map> sortListOfMaps(java.util.List<java.util.Map> listOfMaps)
Sorts a List of Maps by the sessionid,y,x fields found in each of the Maps

Specified by:
sortListOfMaps in class DetailsRequest
Parameters:
listOfMaps - the List to be sorted based upon 3 fields found in the Maps
Returns:
a List of Maps sorted by the 3 fields

doMetaDataQueries

protected void doMetaDataQueries()
                          throws java.sql.SQLException
Add Dynamic data from the Specimens,TissueDiagnosis, and ArrayImage sections

Specified by:
doMetaDataQueries in class DetailsRequest
Throws:
java.sql.SQLException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object