|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.jhu.tmaj.servlet.request.BaseRequest edu.jhu.tmaj.servlet.request.impl.DetailsRequest
public abstract class DetailsRequest
A Details request generally returns a response that is put into a table format. The table format is often exported to a tab-delimited file. First, a Main Query is performed. Other queries, such as queries of dynamic data, add data to rows in the main query. The extra queries find the proper row in the Main Query by using a getRowIdentifier() on a ResultSet from the query. Notes: A rowIdentifier represents the fields that uniquely identify one row. For the scoredImages, the fields are ArrayImageID and SessionID
Field Summary | |
---|---|
protected UserBean |
userBean
|
Fields inherited from class edu.jhu.tmaj.servlet.request.BaseRequest |
---|
password, username |
Constructor Summary | |
---|---|
protected |
DetailsRequest()
|
Method Summary | |
---|---|
protected abstract void |
doMetaDataQueries()
Queries the Dynamic tables to add data obtained from the "Main" query. |
protected void |
doMetaDataQuery(java.lang.String sql,
TableField primaryKeyField,
TableField typeField,
MainTableSection tableSection,
DynamicMetaData dynamicMetaData)
Adds MetaData (for example from the Specimens table) to the data obtained from the Main query |
protected ExpandingMap |
getExpandingMap()
|
protected abstract java.lang.String |
getMainQuerySQL()
Returns the non-dynamic SQL. |
protected abstract ExpandingMap |
getNewExpandingMap()
|
protected abstract StaticFields |
getStaticFields()
Returns fields and their table-names from non-dynamic tables. |
protected Messages |
getWarnings()
|
protected static void |
lookupStaticField(java.util.Map field_idValue,
java.lang.Object field,
java.util.Map<java.lang.Integer,LookupRecord> id_name)
Given a Map and a key of that Map, changes the value of the key based on a Map lookup. |
protected abstract void |
lookupStaticValuesInRecord(java.util.Map<TableField,java.lang.Object> field_value)
|
CommandResponse |
processRequest(UserBean userBean)
This request is executed on the server assuming the username and password returns a valid UserBean. |
protected void |
renameFields(java.util.List<TableField> fieldNamesList)
|
protected abstract java.util.List<java.util.Map> |
sortListOfMaps(java.util.List<java.util.Map> listOfMaps)
Sorts the final List, usually by rowIdentifiers. |
protected abstract 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.BaseRequest |
---|
executeCommand, getPassword, getUsername |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected UserBean userBean
Constructor Detail |
---|
protected DetailsRequest()
Method Detail |
---|
protected Messages getWarnings()
protected ExpandingMap getExpandingMap()
protected abstract ExpandingMap getNewExpandingMap()
protected abstract StaticFields getStaticFields()
protected abstract java.lang.String getMainQuerySQL() throws java.sql.SQLException
java.sql.SQLException
protected abstract void doMetaDataQueries() throws java.sql.SQLException
java.sql.SQLException
protected abstract void lookupStaticValuesInRecord(java.util.Map<TableField,java.lang.Object> field_value)
protected abstract java.util.List<java.util.Map> sortListOfMaps(java.util.List<java.util.Map> listOfMaps)
public final CommandResponse processRequest(UserBean userBean) throws java.sql.SQLException
BaseRequest
processRequest
in class BaseRequest
java.sql.SQLException
protected abstract void verifyUser(UserBean userBean) throws java.sql.SQLException
java.sql.SQLException
protected void renameFields(java.util.List<TableField> fieldNamesList)
protected final void doMetaDataQuery(java.lang.String sql, TableField primaryKeyField, TableField typeField, MainTableSection tableSection, DynamicMetaData dynamicMetaData) throws java.sql.SQLException
sql
- the sql statement to retreive the metadataprimaryKeyTableField
- tableName
- the TableName of the MetaData section, used only for sorting the columnnames.
java.sql.SQLException
protected static void lookupStaticField(java.util.Map field_idValue, java.lang.Object field, java.util.Map<java.lang.Integer,LookupRecord> id_name)
field_idValue
- a Map containing fieldnames and values ex: {specimenid=2; tissueTypeID=5;}field
- the field of the Map whose value is to be looked-up ex:"TissueTypeID"id_name
- the lookup Map. ex: {1="Prostate",2="Bladder"}
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |