DOCUMENTS 5 - PortalScripting API
|
This class encapsulates the basic parameters of a Documents search request. More...
Public Member Functions | |
String | getLastError () |
Function to get the description of the last error that occurred. More... | |
RetrievalField | getSearchField (number index, boolean skipEmpty) |
Get a descriptive object of one of the search fields (conditions), which are declared in the query. More... | |
RetrievalSource | getSource (number index) |
Get a descriptive object of one selected search resource. More... | |
boolean | removeSource (Var refSource) |
Remove a search resource from the query. More... | |
Public Attributes | |
number | filledSearchFieldCount |
The number of filled in search fields in the query (read-only). More... | |
Integer | requestType |
The type (or trigger) of the search request (read-only). More... | |
Integer | searchFieldCount |
The number of declared search fields in the query (read-only). More... | |
String | searchMaskName |
The (technical) name of the selected search mask, if available (read only). More... | |
Integer | sourceCount |
The number of searchable resources involved in the query (read-only). More... | |
Request Type Constants | |
These constants are equally available in each instance of DocQueryParams and in the constructor object. | |
Integer | DIRECT |
Integer code for the requestType "direct fultext search". | |
Integer | EXTENDED |
Integer code for the requestType "extended search". | |
Integer | FOLDER_S |
Integer code for the requestType "static folder". More... | |
Integer | FOLDER_D |
Integer code for the requestType "dynamic folder". More... | |
Integer | REGISTER |
Integer code for the requestType "link register". | |
Integer | REFERENCE |
Integer code for the request type "reference field destination selection". More... | |
Integer | API |
Integer code for the requestType "API search". More... | |
Integer | FILING_PLAN |
Integer code for the requestType "filing plan node". | |
Integer | QUICK_VIEW |
Integer code for the requestType "quick view". More... | |
Integer | SCRIPT_TREE |
Integer code for the request type "script controlled hit tree generation". More... | |
This class encapsulates the basic parameters of a Documents search request.
Only the script-exits "OnSearch" and "FillSearchMask" provide access to such an object. See also Context.getQueryParams().
Scripts can modify the parameters only in the following ways.
String DocQueryParams::getLastError | ( | ) |
Function to get the description of the last error that occurred.
RetrievalField DocQueryParams::getSearchField | ( | number | index, |
boolean | skipEmpty | ||
) |
Get a descriptive object of one of the search fields (conditions), which are declared in the query.
index | The index of the desired search field. The valid range is 0 to (filledSearchFieldCount - 1), if the flag skipEmpty is set. Otherwise the range is 0 to (searchFieldCount - 1). |
skipEmpty | An optional boolean to treat all empty search fields as non-existing. By default all fields can be examined. |
RetrievalSource DocQueryParams::getSource | ( | number | index | ) |
Get a descriptive object of one selected search resource.
index | The integer index of the resource in the internal list. Range: 0 to (sourceCount - 1) |
null
. boolean DocQueryParams::removeSource | ( | Var | refSource | ) |
Remove a search resource from the query.
refSource | Either the current integer index or the id of the resource. |
Integer DocQueryParams::API |
Integer code for the requestType "API search".
(Archive-)FileResultsets, HitResultsets and the SOAP report functions belong to this category.
number DocQueryParams::filledSearchFieldCount |
The number of filled in search fields in the query (read-only).
This is in other words the number of conditions in the query.
Integer DocQueryParams::FOLDER_D |
Integer code for the requestType "dynamic folder".
Listing the contents of such a folder already triggers a search request.
Integer DocQueryParams::FOLDER_S |
Integer code for the requestType "static folder".
In the current release, this type can occur only, if the Documents setting "search field in folder" is enabled.
Integer DocQueryParams::QUICK_VIEW |
Integer code for the requestType "quick view".
Integer DocQueryParams::REFERENCE |
Integer code for the request type "reference field destination selection".
This request type originates from the web dialog, which opens, when a user is editing a file and presses a reference fields select button.
Integer DocQueryParams::requestType |
The type (or trigger) of the search request (read-only).
See the enumeration constants in this class. If Documents encounters a request, which it cannot categorize exactly, it will return the nearest match with respect to the server's internal interfaces.
Integer DocQueryParams::SCRIPT_TREE |
Integer code for the request type "script controlled hit tree generation".
This is a special feature, where a script in the web server process sends a seach request and immediately generates a hit tree from the results. The tabular list is not displayed in this case.
Integer DocQueryParams::searchFieldCount |
The number of declared search fields in the query (read-only).
This count may include fields from a search mask, which have not been filled in.
String DocQueryParams::searchMaskName |
The (technical) name of the selected search mask, if available (read only).
resId
of the first selected resource. Integer DocQueryParams::sourceCount |
The number of searchable resources involved in the query (read-only).