Package wt.query
Class DatabaseSearch
java.lang.Object
wt.query.DatabaseSearch
- All Implemented Interfaces:
Externalizable,Serializable
Utility class for processing the database search part of the integrated
search.
Supported API: true
Extendable: false
Supported API: true
Extendable: false
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic PagingQueryResultdatabaseSearch(Vector classnames, Hashtable criteria, Vector displayAttributes, Vector sortKeys, int pageOffset, int pageRange, String searchFilter, HashMap oidList, Locale locale) Does the database part of the integrated search.static PagingQueryResultlimitedDatabaseSearch(Vector classnames, Hashtable criteria, Vector displayAttributes, Vector sortKeys, int pageOffset, int pageRange, String searchFilter, HashMap oidList, Locale locale) Does the database part of the limited integrated search.
-
Method Details
-
databaseSearch
public static PagingQueryResult databaseSearch(Vector classnames, Hashtable criteria, Vector displayAttributes, Vector sortKeys, int pageOffset, int pageRange, String searchFilter, HashMap oidList, Locale locale) throws WTException Does the database part of the integrated search. Uses the oid list to retrict the search to what was found by the content search. If the oid list is null then this search will do just the database search.
Supported API: true- Parameters:
classnames- A list of the classes (of type Class not String) that this search will use in a compound search. All of the criteria attributes and the sorting attributes must be the same for each of the classes in the list. The sorting must be in the same order and the types of the attributes must be the same.criteria- A series of name value pairs of type String that specify the search criteria.displayAttributes- List of attributes that are used to inflate the attribute values after a search or retrieval of a page.sortKeys- List of sort key strings that the results should be sorted in. The keys are ordered with the first sort key being the first in the list. The string is of the format:: Where attribute name is the name of the column to be sorted on and descending is a boolean that specifies true for descending and false for ascending order. False is the default if no value is specified. pageOffset- For the database paging of the search results this is the page offset into the results that is being requested. If the session id has been set to a valid session then a new query is not done but the offset is used to return a specific page of the query results. The first page is 0.pageRange- For the database paging of the search results this sets the size of a page.searchFilter- Can be set to either ALL_VERSIONS or ALL_ITERATIONS. The ALL_VERSIONS will return the latest iteration of each of the versions for the iterated object. ALL_ITERATIONS will return all iterations of all versions of the iterated object.oidList-locale- Locale of the client that is executed this method.- Returns:
- PagingQueryResult
- Throws:
WTException
-
limitedDatabaseSearch
public static PagingQueryResult limitedDatabaseSearch(Vector classnames, Hashtable criteria, Vector displayAttributes, Vector sortKeys, int pageOffset, int pageRange, String searchFilter, HashMap oidList, Locale locale) throws WTException Does the database part of the limited integrated search. Uses the oid list to retrict the search to what was found by the content search. If the oid list is null then this search will do just the database search.
Supported API: true- Parameters:
classnames- A list of the classes (of type Class not String) that this search will use in a compound search. All of the criteria attributes and the sorting attributes must be the same for each of the classes in the list. The sorting must be in the same order and the types of the attributes must be the same.criteria- A series of name value pairs of type String that specify the search criteria.displayAttributes- List of attributes that are used to inflate the attribute values after a search or retrieval of a page.sortKeys- List of sort key strings that the results should be sorted in. The keys are ordered with the first sort key being the first in the list. The string is of the format:: Where attribute name is the name of the column to be sorted on and descending is a boolean that specifies true for descending and false for ascending order. False is the default if no value is specified. pageOffset- For the database paging of the search results this is the page offset into the results that is being requested. If the session id has been set to a valid session then a new query is not done but the offset is used to return a specific page of the query results. The first page is 0.pageRange- For the database paging of the search results this sets the size of a page.searchFilter- Can be set to either ALL_VERSIONS or ALL_ITERATIONS. The ALL_VERSIONS will return the latest iteration of each of the versions for the iterated object. ALL_ITERATIONS will return all iterations of all versions of the iterated object.oidList-locale- Locale of the client that is executed this method.- Returns:
- PagingQueryResult
- Throws:
WTException
-