public class SearchBarControlBean extends BaseCompositeViewControlPageBean
BaseViewBean.ClientIdsContentProvider
fCompositeNamingContainer
clientIds, initialized
fExpireWithPageFlow
DATA_BINDING_CLIENTS, EMPTY_RESOURCES, OUTCOME_ERROR, OUTCOME_OK, resourcesProviders
Constructor and Description |
---|
SearchBarControlBean() |
Modifier and Type | Method and Description |
---|---|
protected void |
addInfoMessage(String message)
Helper method for adding an info message to the faces context
|
protected void |
afterRenderResponse()
Clients should overwrite this method to perform custom actions after the
view got rendered.
|
protected void |
applySearchOptionPreferences()
Apply the search option preferences for the current user
|
protected void |
beforeInvokeApplication()
Clients should overwrite this method to perform custom actions before an
action method is invoked.
|
protected void |
beforeRenderResponse()
Clients should overwrite this method to perform custom actions before the
view gets rendered.
|
String |
cancelSearchOptions()
Action Handler for the 'Cancel' button on the 'Options' tab of the SearchBar control
|
String |
changeActiveSavedSearch()
Action Handler for the 'onchange' hidden command associated with the saved searches dropdown on the 'Saved' tab
|
String |
clearSearchForm()
Action Handler for the 'Clear' button on all tabs of the SearchBar control
|
String |
constructSearchQueryString()
Action Handler for the 'Go' button on all tabs of the SearchBar control
|
protected ISearchStateOptions |
createSearchStateOptions() |
protected ISearchStateOptions |
createSearchStateOptions(boolean forSearchOnDisplay) |
String |
deleteSavedSearch()
Action Handler for the 'Delete' button on the 'Saved' tab of the SearchBar control
|
protected String |
getActiveQueryStateString() |
protected String |
getActiveQueryStateString(ISearchStateOptions searchStateOptions) |
ISavedSearch |
getActiveSavedSearch()
Gets the active saved search object for the SearchBar control.
|
ISearchQuery |
getActiveSearchQuery()
Gets the active search query object for the SearchBar control.
|
String |
getActiveTabValue() |
String |
getAsyncGoRefresh() |
ISelectItemProvider[] |
getCategorizedSavedSearches() |
Map<String,Object> |
getCurrentSearchOptions() |
String |
getDefaultCommandId()
Return the ID for the default searchbar command
|
String |
getDefaultFocusId()
Return the ID for the searchbar control that should have the initial focus
|
EncodersBean |
getEncodersBean() |
protected String |
getInitialSearchTab()
Return the initial search tab value for the current user
|
protected String |
getInitialSelectedSavedSearch()
Return the initial selected saved search value for the current user
|
long |
getMaxResultsMaxValue() |
ISearchQuery |
getResultSearchQuery() |
protected Boolean |
getRunSearchOnDisplay()
Return the runSearchOnDisplay value for the current user
|
ISavedSearchProvider |
getSavedSearchProvider() |
Boolean |
getSaveSearchCompleted() |
ISearchOptionsManager |
getSearchOptionsManager() |
ISearchQueryFactory |
getSearchQueryFactory() |
String |
getSimpleSearchRefinedTabText() |
String |
getSimpleSearchTabText() |
boolean |
isAdvancedSearchAvailable() |
boolean |
isClearFormButtonAvailable() |
boolean |
isKeywordsBlockVisible()
Returns true if the keywords block should be rendered
|
boolean |
isKeywordsFieldAvailable() |
boolean |
isMaxResultsFieldAvailable() |
boolean |
isRefinePanelVisible() |
boolean |
isRefineSearchButtonAvailable() |
boolean |
isSavedSearchesEmpty() |
boolean |
isSaveSearchAvailable() |
boolean |
isSearchBarOnAdvancedTab()
Returns true if the active searchbar tab is the the 'Advanced' tab
|
boolean |
isSearchBarOnOptionsTab()
Returns true if the active searchbar tab is the the 'Options' tab
|
boolean |
isSearchBarOnSavedTab()
Returns true if the active searchbar tab is the the 'Saved' tab
|
boolean |
isSearchBarOnSimpleTab()
Returns true if the active searchbar tab is the the 'Search' tab
|
boolean |
isShowingSavedDetails() |
boolean |
isSimpleSearchAvailable() |
boolean |
isSimpleSearchRefining() |
boolean |
isUseAsyncGoButton() |
boolean |
isUseOrConditionAvailable() |
boolean |
isUserSearchOptionsAvailable() |
String |
persistSearchOptions()
Action Handler for the 'Save' button on the 'Options' tab of the SearchBar control
|
String |
reset()
Helper method mostly for debugging that will reset the state of the page bean to the
default values
|
String |
saveSearchQuery()
Action Handler for the 'Save' icon on the 'Search' and 'Advanced' tab of the SearchBar control
|
void |
setActiveSavedSearch(ISavedSearch activeSavedSearch)
Sets the active saved search object for the SearchBar control.
|
void |
setActiveSearchQuery(ISearchQuery activeSearchQuery)
Sets the active search query object for the SearchBar control.
|
void |
setActiveTabValue(String activeTabValue) |
void |
setAdvancedSearchAvailable(boolean advancedSearchAvailable) |
void |
setAsyncGoRefresh(String asyncGoRefresh) |
void |
setClearFormButtonAvailable(boolean clearFormButtonAvailable) |
void |
setEncodersBean(EncodersBean encodersBean) |
void |
setKeywordsFieldAvailable(boolean keywordsFieldAvailable) |
protected void |
setLastSearchState(String lastSearchState)
Setter for the query string preference
|
void |
setMaxResultsFieldAvailable(boolean maxResultsFieldAvailable) |
void |
setMaxResultsMaxValue(long maxResultsMaxValue) |
void |
setRefinePanelVisible(boolean isVisible) |
void |
setRefineSearchButtonAvailable(boolean refineSearchButtonAvailable) |
void |
setSavedSearchProvider(ISavedSearchProvider savedSearchProvider) |
void |
setSaveSearchAvailable(boolean saveSearchAvailable) |
void |
setSaveSearchCompleted(Boolean saveSearchCompleted) |
void |
setSearchOptionsManager(ISearchOptionsManager searchOptionsManager) |
void |
setSearchQueryFactory(ISearchQueryFactory searchQueryFactory) |
void |
setShowingSavedDetails(boolean showingSavedDetails) |
void |
setSimpleSearchAvailable(boolean simpleSearchAvailable) |
void |
setSimpleSearchRefining(boolean simpleSearchRefining) |
protected void |
setupVisibleControls() |
void |
setUseAsyncGoButton(boolean useAsyncGoButton) |
void |
setUseOrConditionAvailable(boolean useOrConditionAvailable) |
void |
setUserSearchOptionsAvailable(boolean userSearchOptionsAvailable) |
String |
updateSavedSearchQuery()
Action Handler for the 'Save' icon on the 'Saved' tab of the SearchBar control
|
findComponentInRoot, getClientIds, getCompositeViewAbsoluteControlId, getCompositeViewControlId, getCompositeViewNamingContainer, getPropertyOrBindingValue, setCompositeViewNamingContainer
afterApplyRequestValues, afterInvokeApplication, afterPhase, afterProcessValidations, afterRestoreView, afterUpdateModelValues, beforeApplyRequestValues, beforePhase, beforeProcessValidations, beforeRestoreView, beforeUpdateModelValues, callInitialize, findComponent, getApplicationScope, getPhaseId, getRealPath, getRequestParam, getRequestScope, getSessionScope, gotoPage, gotoPage, initialize, isAsyncRequest, preRenderResponse, release, resetPageFlowStorage, streamFileDataToResponse
getExpireWithPageFlow, setExpireWithPageFlow, valueBound, valueUnbound
createMethodBinding, createMethodExpression, createValueBinding, createValueExpression, createValueExpression, error, error, error, error, error, getBean, getFacesContext, getLocale, getResourceInputStream, getResources, getResourcesProvider, getRootCause, getStackTrace, getTreeAttribute, isUserInRole, log, log, log, putTreeAttribute, resetDataBindingClients, resolveDataBinding, resolveDataBinding, resolveExpression, setValue
public static final String TAB_VALUE_SIMPLE_SEARCH
public static final String TAB_VALUE_ADVANCED_SEARCH
public static final String TAB_VALUE_SAVED_SEARCHES
public static final String TAB_VALUE_SEARCH_OPTIONS
protected static final String CONTROL_ID_KEYWORDS_TEXT_INPUT
protected static final String CONTROL_ID_SIMPLE_SEARCH_ASYNC_GO_BUTTON
protected static final String CONTROL_ID_SIMPLE_SEARCH_GO_BUTTON
protected static final String CONTROL_ID_REFINED_SEARCH_GO_BUTTON
protected static final String CONTROL_ID_REFINED_SEARCH_ASYNC_GO_BUTTON
protected static final String CONTROL_ID_SAVE_SEARCH_ASYNC_GO_BUTTON
protected static final String CONTROL_ID_SAVE_SEARCH_GO_BUTTON
protected static final String CONTROL_ID_SAVE_SEARCH_OPTIONS_BUTTON
protected static final String CONTROL_ID_SAVED_SEARCHES_DROPDOWN
protected static final String CONTROL_ID_INITIAL_SEARCHTAB_DROPDOWN
protected static final String CONTROL_ID_MAX_RESULTS
protected static final String CONTROL_ID_SIMPLE_SUBMIT_BUTTONS_PANEL
protected String fActiveTabValue
protected String fPreviousTabValue
protected ISearchQueryFactory fSearchQueryFactory
protected ISearchQuery fActiveSearchQuery
protected ISearchQuery fResultSearchQuery
protected ISavedSearch fActiveSavedSearch
protected ISavedSearchProvider fSavedSearchProvider
protected ISearchOptionsManager fSearchOptionsManager
protected boolean fNeedsUserOptionsApplied
protected SecureRandom fRandomNumberGenerator
protected Boolean fUseAsyncGoButton
protected String fAsyncGoRefresh
protected Boolean fSimpleSearchAvailable
protected Boolean fRefineSearchButtonAvailable
protected Boolean fAdvancedSearchAvailable
protected Boolean fSaveSearchAvailable
protected Boolean fUserSearchOptionsAvailable
protected Boolean fMaxResultsFieldAvailable
protected Long fMaxResultsMaxValue
protected Boolean fKeywordsFieldAvailable
protected Boolean fClearFormButtonAvailable
protected Boolean fUseOrConditionAvailable
protected transient EncodersBean fEncodersBean
protected transient Boolean fSaveSearchCompleted
public ISearchQuery getResultSearchQuery()
public Boolean getSaveSearchCompleted()
public void setSaveSearchCompleted(Boolean saveSearchCompleted)
saveSearchCompleted
- the saveSearchCompleted to setprotected void afterRenderResponse()
BaseViewBean
afterRenderResponse
in class BaseViewBean
public EncodersBean getEncodersBean()
public void setEncodersBean(EncodersBean encodersBean)
encodersBean
- the encodersBean to setpublic String getDefaultCommandId()
public String getDefaultFocusId()
public String reset()
public void setSearchQueryFactory(ISearchQueryFactory searchQueryFactory)
searchQueryFactory
- the searchQueryFactory to setpublic ISearchQueryFactory getSearchQueryFactory()
public ISearchQuery getActiveSearchQuery()
public void setActiveSearchQuery(ISearchQuery activeSearchQuery)
activeSearchQuery
- The activeSearchQuery to set.public ISavedSearch getActiveSavedSearch()
public void setActiveSavedSearch(ISavedSearch activeSavedSearch)
activeSavedSearch
- The activeSavedSearch to set.public void setSavedSearchProvider(ISavedSearchProvider savedSearchProvider)
savedSearchProvider
- The savedSearchProvider to set.public ISavedSearchProvider getSavedSearchProvider()
public ISearchOptionsManager getSearchOptionsManager()
public void setSearchOptionsManager(ISearchOptionsManager searchOptionsManager)
searchOptionsManager
- the searchOptionsManager to setpublic String getActiveTabValue()
public void setActiveTabValue(String activeTabValue)
activeTabValue
- the activeTabValue to setpublic Map<String,Object> getCurrentSearchOptions()
public boolean isSearchBarOnSimpleTab()
public boolean isSearchBarOnAdvancedTab()
public boolean isSearchBarOnOptionsTab()
public boolean isSearchBarOnSavedTab()
public boolean isKeywordsBlockVisible()
public boolean isRefinePanelVisible()
public void setRefinePanelVisible(boolean isVisible)
public boolean isSavedSearchesEmpty()
protected void setupVisibleControls()
protected void beforeInvokeApplication()
BaseViewBean
beforeInvokeApplication
in class BaseViewBean
protected void beforeRenderResponse()
BaseViewBean
beforeRenderResponse
in class BaseViewBean
protected String getInitialSearchTab()
protected String getInitialSelectedSavedSearch()
protected Boolean getRunSearchOnDisplay()
protected void applySearchOptionPreferences()
public String persistSearchOptions()
public String cancelSearchOptions()
public String saveSearchQuery()
public String updateSavedSearchQuery()
public String changeActiveSavedSearch()
public String constructSearchQueryString()
public String deleteSavedSearch()
public String clearSearchForm()
protected String getActiveQueryStateString()
protected String getActiveQueryStateString(ISearchStateOptions searchStateOptions)
protected void setLastSearchState(String lastSearchState)
lastSearchState
- the new value for the lastsearchstate preferenceprotected ISearchStateOptions createSearchStateOptions()
protected ISearchStateOptions createSearchStateOptions(boolean forSearchOnDisplay)
protected void addInfoMessage(String message)
message
- public boolean isAdvancedSearchAvailable()
public void setAdvancedSearchAvailable(boolean advancedSearchAvailable)
advancedSearchAvailable
- the advancedSearchAvailable to setpublic String getAsyncGoRefresh()
public void setAsyncGoRefresh(String asyncGoRefresh)
asyncGoRefresh
- the asyncGoRefresh to setpublic boolean isClearFormButtonAvailable()
public void setClearFormButtonAvailable(boolean clearFormButtonAvailable)
clearFormButtonAvailable
- the clearFormButtonAvailable to setpublic boolean isKeywordsFieldAvailable()
public void setKeywordsFieldAvailable(boolean keywordsFieldAvailable)
keywordsFieldAvailable
- the keywordsFieldAvailable to setpublic boolean isMaxResultsFieldAvailable()
public void setMaxResultsFieldAvailable(boolean maxResultsFieldAvailable)
maxResultsFieldAvailable
- the maxResultsFieldAvailable to setpublic long getMaxResultsMaxValue()
public void setMaxResultsMaxValue(long maxResultsMaxValue)
maxResultsMaxValue
- the maxResultsMaxValue to setpublic boolean isRefineSearchButtonAvailable()
public void setRefineSearchButtonAvailable(boolean refineSearchButtonAvailable)
refineSearchButtonAvailable
- the refineSearchButtonAvailable to setpublic boolean isSaveSearchAvailable()
public void setSaveSearchAvailable(boolean saveSearchAvailable)
saveSearchAvailable
- the saveSearchAvailable to setpublic boolean isSimpleSearchAvailable()
public void setSimpleSearchAvailable(boolean simpleSearchAvailable)
simpleSearchAvailable
- the simpleSearchAvailable to setpublic boolean isUseAsyncGoButton()
public void setUseAsyncGoButton(boolean useAsyncGoButton)
useAsyncGoButton
- the useAsyncGoButton to setpublic boolean isUseOrConditionAvailable()
public void setUseOrConditionAvailable(boolean useOrConditionAvailable)
useOrConditionAvailable
- the useOrConditionAvailable to setpublic boolean isUserSearchOptionsAvailable()
public void setUserSearchOptionsAvailable(boolean userSearchOptionsAvailable)
userSearchOptionsAvailable
- the userSearchOptionsAvailable to setpublic boolean isShowingSavedDetails()
public void setShowingSavedDetails(boolean showingSavedDetails)
showingSavedDetails
- the showingSavedDetails to setpublic boolean isSimpleSearchRefining()
public void setSimpleSearchRefining(boolean simpleSearchRefining)
simpleSearchRefining
- the simpleSearchRefining to setpublic String getSimpleSearchTabText()
public String getSimpleSearchRefinedTabText()
public ISelectItemProvider[] getCategorizedSavedSearches()