public final class DCSQueryForm
extends org.apache.struts.action.ActionForm
implements java.io.Serializable
SimpleLuceneIndex
. This class works in conjuction with
the DCSQueryAction
Struts Action
class.Modifier and Type | Class and Description |
---|---|
class |
DCSQueryForm.ParamPair
Holds paramter, value pairs.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEFAULT_REC_SORT |
static java.lang.String |
RELEVANCE_REC_SORT |
Constructor and Description |
---|
DCSQueryForm()
Constructor for the DCSQueryForm object
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getContextURL()
Gets the contextURL attribute of the DCSQueryForm object
|
SortWidget |
getCurrentSortWidget() |
java.util.List |
getEditors()
return the list of Editors for the currently selected collection; we don't
use "selectedCollection" but rather getSelectedSet().getSetSpec() because
the former does not seem to be properly initialized after system restart?
|
java.lang.String |
getEnd()
Gets the ending index for the records that will be displayed.
|
java.util.List |
getFormatLabels()
Gets the formatLabels attribute of the DCSQueryForm object
|
java.util.List |
getFormats()
Gets all possible metadata formats that may be disiminated by the
RepositoryManager.
|
java.util.List |
getHits() |
java.util.List |
getIdMapperErrorLabels()
Gets the idMapperErrorLabels, as strings.
|
java.util.List |
getIdMapperErrors()
Gets the idMapperErrors that are in the index, as integer strings.
|
java.util.List |
getIndexedAccessionStatuses()
Gets the indexedAccessionStatuses attribute of the DCSQueryForm object
|
java.util.List |
getIndexedFormats()
Gets all formats that exist natively in the index.
|
java.util.List |
getIndexedFormatsLabels()
Gets all formats that exist natively in the index.
|
SortWidget |
getLastEditorWidget() |
SortWidget |
getLastTouchDateWidget() |
java.lang.String |
getLength()
Gets the length of iterations to loop over the results array.
|
java.lang.String |
getMetadata()
Gets the metadata attribute of the DCSQueryForm object
|
java.lang.String |
getNextResultsUrl()
Gets the HTTP parameters that should be used to retrieve the next set of
results.
|
java.lang.String |
getNonPaigingParams()
Gets all the parameters that existed in the request other than those used
for paiging.
|
java.util.ArrayList |
getNrqParams()
Gets all request parameters except the refined query Rq parameter.
|
int |
getNumPagingRecords()
Gets the numPagingRecords attribute of the DCSQueryForm object
|
java.lang.String |
getNumResults()
Gets the numResults attribute of the DCSQueryForm object
|
java.lang.String |
getOffset()
Gets the offset into the results array to begin iterating.
|
int |
getPaigingParam()
the current result page.
|
int |
getPaigingParam(java.lang.String id) |
java.lang.String |
getPrevResultsUrl()
Gets the HTTP parameters that should be used to retrieve the previous set
of results.
|
java.lang.String |
getQ()
Gets the query string entered by the user.
|
java.lang.String |
getQe()
Gets the query string entered by the user, encoded for use in a URL string.
|
SortWidget |
getRecordIdWidget() |
java.lang.String |
getReportTitle()
Gets the reportTitle attribute of the DCSQueryForm object
|
java.lang.String |
getResultsPerPage()
A string representation of the numPagingRecords attribute
|
java.lang.String[] |
getResultsPerPageOptions()
Gets the resultsPerPageOptions attribute of the DCSQueryForm object
|
java.lang.String |
getRq()
Gets the refined query string entered by the user, used to search within
results.
|
java.lang.String |
getSc()
Gets the collection that has been selected by the user in the UI via a
Select tag.
|
java.lang.String |
getScparams()
Gets the selected collection(s) parameter to be inserted in the URL that
gets the next set of results.
|
java.lang.String[] |
getScs()
Gets the collections that have been selected by the user in the UI.
|
java.lang.String |
getSearchMode()
Gets the searchMode attribute of the DCSQueryForm object
|
java.lang.String[] |
getselectedAccessionStatuses()
DESCRIPTION
|
java.lang.String[] |
getSelectedIdMapperErrors()
Gets the selectedIdMapperErrors attribute of the DCSQueryForm object
|
java.lang.String[] |
getSes()
Gets the ses (Selected Editors) attribute of the DCSBrowseForm object
|
java.lang.String[] |
getSfmts()
Gets the selected formats.
|
java.lang.String |
getShowQueryOptions()
Gets the showQueryOptions attribute of the DCSQueryForm object
|
java.lang.String |
getSortField()
Gets the sortField attribute of the DCSQueryForm object
|
java.lang.String |
getSortWidgetParams()
Gets all the parameters that existed in the request other than those used
for paiging or sorting.
|
java.util.Map |
getSortWidgets()
The sortField of the widgets must be indexed!
The sortWidgets key must match the sortField for each widget.
|
java.lang.String[] |
getSrcs()
Gets the ses (Selected Creators) attribute of the DCSBrowseForm object
|
java.lang.String[] |
getSss()
Gets the sss (selectedStatuses) attribute of the DCSBrowseForm object
|
java.lang.String |
getStart()
Gets the starting index for the records that will be displayed.
|
java.util.Map |
getStatuses()
return the list of Statuses for the currently selected collection; we don't
use "selectedCollection" but rather getSelectedSet().getSetSpec() because
the former does not seem to be properly initialized after system restart?
|
SortWidget |
getStatusWidget() |
java.lang.String |
getVld()
Gets the vld attribute of the DCSQueryForm object
|
void |
reset(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
DESCRIPTION
|
void |
setContextURL(java.lang.String contextURL)
Sets the contextURL attribute of the DCSQueryForm object
|
static void |
setDebug(boolean db)
Sets the debug attribute of the object
|
void |
setEditors(java.util.List editors)
Sets the editors attribute of the DCSBrowseForm object
|
void |
setFormats(java.util.List formats)
Sets the formats attribute of the DCSQueryForm object
|
void |
setIdMapperErrors(java.util.List errors)
Sets the id mapper errors that are available in the index.
|
void |
setIndexedAccessionStatuses(java.util.List statusus)
Sets the indexedAccessionStatuses attribute of the DCSQueryForm object
|
void |
setIndexedFormats(java.util.List formats)
Gets all formats that exist natively in the index.
|
void |
setIndexedFormatsLabels(java.util.List formatsLabels)
Gets all formats that exist natively in the index.
|
void |
setMetadata(java.lang.String metadata)
Sets the metadata attribute of the DCSQueryForm object
|
void |
setNonPaigingParams(java.lang.String nonPaigingParams)
Sets the nonPaigingParams attribute of the DCSQueryForm object
|
void |
setNumPagingRecords(int numPagingRecords)
Sets the number of records to display per paiging request.
|
void |
setQ(java.lang.String queryString)
Sets the q attribute of the DCSQueryForm object
|
void |
setReportTitle(java.lang.String reportTitle)
Sets the reportTitle attribute of the DCSQueryForm object
|
void |
setRequest(javax.servlet.http.HttpServletRequest request)
Sets the request attribute of the DCSQueryForm object.
|
void |
setResults(SearchHelper results)
Sets the search results returned by the
SimpleLuceneIndex after sorting them. |
void |
setResultsPerPage(java.lang.String s)
Sets the resultsPerPage attribute of the DCSQueryForm object
|
void |
setRq(java.lang.String refineQueryString)
Sets the refined query string entered by the user, used to search within
results.
|
void |
setSc(java.lang.String selectedCollection)
Sets the collection that has been selected by the user in the UI via a
Select tag.
|
void |
setScs(java.lang.String[] selectedCollections)
Sets the collection that has been selected by the user in the UI.
|
void |
setSearchMode(java.lang.String s)
Sets the searchMode attribute of the DCSQueryForm object
|
void |
setselectedAccessionStatuses(java.lang.String[] selectedAccessionStatuses)
DESCRIPTION
|
void |
setSelectedIdMapperErrors(java.lang.String[] selectedIdMapperErrors)
Sets the selectedIdMapperErrors attribute of the DCSQueryForm object
|
void |
setSes(java.lang.String[] selectedEditors)
Sets the collection that has been selected by the user in the UI.
|
void |
setSfmts(java.lang.String[] selectedFormats)
Sets the selected formats.
|
void |
setShowQueryOptions(java.lang.String showQueryOptions)
Sets the showQueryOptions attribute of the DCSQueryForm object
|
void |
setSortField(java.lang.String sortField)
Sets the sortField attribute of the DCSQueryForm object
|
void |
setSortWidgetParams(java.lang.String sortWidgetParams)
Sets the sortWidgetParams attribute of the DCSQueryForm object.
|
void |
setSrcs(java.lang.String[] selectedCreators)
Sets the collection that has been selected by the user in the UI.
|
void |
setSss(java.lang.String[] selectedStatuses)
Sets the sss (selectedStatuses) attribute of the DCSBrowseForm object
|
void |
setStart(int start)
Sets the starting index for the records to display.
|
void |
setStatuses(java.util.Map statuses)
Sets the statuses attribute of the DCSBrowseForm object
|
void |
setVld(java.lang.String v)
Sets the vld attribute of the DCSQueryForm object
|
public static java.lang.String DEFAULT_REC_SORT
public static java.lang.String RELEVANCE_REC_SORT
public java.lang.String[] getResultsPerPageOptions()
public void setSortField(java.lang.String sortField)
sortField
- The new sortField valuepublic java.lang.String getSortField()
public java.util.Map getSortWidgets()
public SortWidget getCurrentSortWidget()
public SortWidget getRecordIdWidget()
public SortWidget getLastEditorWidget()
public SortWidget getStatusWidget()
public SortWidget getLastTouchDateWidget()
public java.lang.String getResultsPerPage()
public void setResultsPerPage(java.lang.String s)
s
- The new resultsPerPage valuepublic java.lang.String getSearchMode()
public void setSearchMode(java.lang.String s)
s
- The new searchMode valuepublic java.lang.String getShowQueryOptions()
public void setShowQueryOptions(java.lang.String showQueryOptions)
showQueryOptions
- The new showQueryOptions valuepublic java.lang.String getContextURL()
public void setContextURL(java.lang.String contextURL)
contextURL
- The new contextURL valuepublic java.util.List getEditors()
public void setEditors(java.util.List editors)
editors
- The new editors valuepublic java.lang.String getVld()
public void setVld(java.lang.String v)
v
- The new vld valuepublic java.lang.String[] getSrcs()
public void setSrcs(java.lang.String[] selectedCreators)
selectedCreators
- The new ses valuepublic java.lang.String[] getSes()
public void setSes(java.lang.String[] selectedEditors)
selectedEditors
- The new ses valuepublic java.util.Map getStatuses()
public void setStatuses(java.util.Map statuses)
statuses
- The new statuses valuepublic java.lang.String[] getSss()
public void setSss(java.lang.String[] selectedStatuses)
selectedStatuses
- The new sss valuepublic void setIdMapperErrors(java.util.List errors)
errors
- The ID mapper errors, as a list of integers.public java.util.List getIdMapperErrors()
public java.util.List getIdMapperErrorLabels()
public void setIndexedAccessionStatuses(java.util.List statusus)
statusus
- The new indexedAccessionStatuses valuepublic java.util.List getIndexedAccessionStatuses()
public java.util.List getFormats()
public void setFormats(java.util.List formats)
formats
- The new formats valuepublic java.util.List getIndexedFormats()
public void setIndexedFormats(java.util.List formats)
formats
- The new indexedFormats valuepublic java.util.List getIndexedFormatsLabels()
public void setIndexedFormatsLabels(java.util.List formatsLabels)
formatsLabels
- The new indexedFormatsLabels valuepublic java.util.List getFormatLabels()
public java.lang.String[] getSfmts()
public void setSfmts(java.lang.String[] selectedFormats)
selectedFormats
- The new sfmts valuepublic java.lang.String getSc()
Sample HTML code using Struts:
<html:select property="sc" size="1" >
<html:options name="queryForm" property="collections"
labelProperty="collectionLabels"/>
</html:select>
public void setSc(java.lang.String selectedCollection)
selectedCollection
- The new sc valuepublic java.lang.String[] getScs()
Sample HTML code using Struts:
<html:select property="scs" size="5" multiple="t">
<html:options name="queryForm" property="collections"
labelProperty="collectionLabels"/>
</html:select>
public java.lang.String[] getSelectedIdMapperErrors()
public java.lang.String[] getselectedAccessionStatuses()
public void setselectedAccessionStatuses(java.lang.String[] selectedAccessionStatuses)
selectedAccessionStatuses
- DESCRIPTIONpublic void setSelectedIdMapperErrors(java.lang.String[] selectedIdMapperErrors)
selectedIdMapperErrors
- The new selectedIdMapperErrors valuepublic void reset(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)
reset
in class org.apache.struts.action.ActionForm
mapping
- DESCRIPTIONrequest
- DESCRIPTIONpublic void setScs(java.lang.String[] selectedCollections)
selectedCollections
- The new sc valuepublic java.lang.String getScparams()
public void setResults(SearchHelper results)
SimpleLuceneIndex
after sorting them. we DON'T want to sort results if:
results
- The new results value.public void setMetadata(java.lang.String metadata)
metadata
- The new metadata valuepublic java.lang.String getMetadata()
public java.util.List getHits()
public java.lang.String getNumResults()
public java.lang.String getQ()
public java.lang.String getQe()
public void setQ(java.lang.String queryString)
queryString
- The new q valuepublic java.lang.String getRq()
public void setRq(java.lang.String refineQueryString)
refineQueryString
- The new rq valuepublic java.util.ArrayList getNrqParams()
public void setReportTitle(java.lang.String reportTitle)
reportTitle
- The new reportTitle valuepublic java.lang.String getReportTitle()
public void setStart(int start)
start
- The new start valuepublic java.lang.String getStart()
public java.lang.String getEnd()
public java.lang.String getOffset()
public java.lang.String getLength()
public int getNumPagingRecords()
public void setNumPagingRecords(int numPagingRecords)
numPagingRecords
- The new numPagingRecords valuepublic java.lang.String getNextResultsUrl()
public java.lang.String getPrevResultsUrl()
public void setRequest(javax.servlet.http.HttpServletRequest request)
request
- The new request valuepublic void setNonPaigingParams(java.lang.String nonPaigingParams)
nonPaigingParams
- The new nonPaigingParams valuepublic final java.lang.String getNonPaigingParams()
public int getPaigingParam()
public int getPaigingParam(java.lang.String id)
public void setSortWidgetParams(java.lang.String sortWidgetParams)
Used by the sortWidget (see tags/sortWidget.tag) to contstruct a URL that will reproduce search but accomodate new sorting, ordering, and paiging params.
sortWidgetParams
- The new sortWidgetParams valuepublic final java.lang.String getSortWidgetParams()
public static void setDebug(boolean db)
db
- The new debug value