|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.struts.action.Action | +--uk.ac.ebi.intact.application.intSeq.struts.framework.IntactBaseAction
Super class for all Intact related action classes.
completed by shuet (shuet@ebi.ac.uk) with the ManageBlastResult
method.
Field Summary | |
static java.lang.String |
INTACT_ERROR
The global Intact error key. |
static org.apache.log4j.Logger |
logger
|
Fields inherited from class org.apache.struts.action.Action |
ACTION_SERVLET_KEY, APPLICATION_KEY, DATA_SOURCE_KEY, defaultLocale, ERROR_KEY, EXCEPTION_KEY, FORM_BEANS_KEY, FORWARDS_KEY, LOCALE_KEY, MAPPING_KEY, MAPPINGS_KEY, MESSAGE_KEY, MESSAGES_KEY, MULTIPART_KEY, PLUG_INS_KEY, REQUEST_PROCESSOR_KEY, servlet, SERVLET_KEY, TRANSACTION_TOKEN_KEY |
Constructor Summary | |
IntactBaseAction()
|
Method Summary | |
protected void |
addError(java.lang.String key)
Adds an error with given key. |
protected void |
addError(java.lang.String key,
java.lang.String value)
Adds an error with given key and value. |
protected void |
clearErrors()
Clear error container. |
protected void |
doSimilaritySearch(java.lang.String sequence,
javax.servlet.http.HttpServletRequest request)
Perform the similarity search operation. Check the protein sequence and similarity search program parameters. |
protected java.lang.String |
getProperty(java.lang.String propName)
returns a value stored in a properties file. |
protected java.lang.String |
getProperty(java.lang.String propName,
java.lang.String defaultValue)
eturns a value stored in a properties file, eventually a default value. |
protected java.lang.String |
getProteinsSrsUrl(java.lang.String searchString)
|
protected java.lang.String |
getSequenceSrsUrl(java.lang.String proteinAc)
|
protected javax.servlet.http.HttpSession |
getSession(javax.servlet.http.HttpServletRequest request)
Returns the session from given request. |
protected boolean |
isEmptyError()
answer the question : "is the error set empty ?" |
protected java.util.ArrayList |
ManageBlastResult(java.lang.String sequence,
java.lang.String commLine,
java.lang.String perc_base,
java.lang.String param)
ManageBlastResult can be called from different action classes, to manage the execution of the command line provided and to retrieve alignment results from the parsing. |
protected void |
saveErrors(javax.servlet.http.HttpServletRequest request)
Saves the errors in given request for |
Methods inherited from class org.apache.struts.action.Action |
execute, execute, generateToken, getDataSource, getDataSource, getLocale, getResources, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, perform, perform, resetToken, saveErrors, saveMessages, saveToken, setLocale, setServlet, toHex |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static org.apache.log4j.Logger logger
public static final java.lang.String INTACT_ERROR
Constructor Detail |
public IntactBaseAction()
Method Detail |
protected java.lang.String getProperty(java.lang.String propName)
propName
- the property name
protected java.lang.String getProperty(java.lang.String propName, java.lang.String defaultValue)
propName
- propName the property namedefaultValue
- the default value in case the property is not found
protected javax.servlet.http.HttpSession getSession(javax.servlet.http.HttpServletRequest request)
request
- the request to get the session from.
request
.protected void clearErrors()
protected void addError(java.lang.String key)
key
- the error key. This value is looked up in the
IntactResources.properties bundle.protected void addError(java.lang.String key, java.lang.String value)
key
- the error key. This value is looked up in the
IntactResources.properties bundle.value
- the value to substitute for the first place holder in the
IntactResources.properties bundle.protected boolean isEmptyError()
protected void saveErrors(javax.servlet.http.HttpServletRequest request)
request
- the request to save errors.protected java.util.ArrayList ManageBlastResult(java.lang.String sequence, java.lang.String commLine, java.lang.String perc_base, java.lang.String param) throws IntactException
sequence
- which is aligned against sequences of the whole IntAct Database.commLine
- - the alignment algorithm is run in a server thanks to this command line
which is defined in the web.xml file.perc_base
- is the minimum percentage identity required to validate the results.param
- is the maximum E Value allowed to validate the results.
IntactException
protected void doSimilaritySearch(java.lang.String sequence, javax.servlet.http.HttpServletRequest request)
if (false == isEmptyError()) { // FOrward to an error page. return mapping.findForward(SeqIdConstants.FORWARD_FAILURE); }
sequence
- the protein sequence to work on.request
- HttpRequest to record Errors and using the session.protected java.lang.String getProteinsSrsUrl(java.lang.String searchString)
protected java.lang.String getSequenceSrsUrl(java.lang.String proteinAc)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |