MediaWiki REL1_33
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. More...
Go to the source code of this file.
Functions | |
buildCommonApiParams ( $isScrollable=true) | |
The set of api parameters that are shared between api calls that call the SearchEngine. | |
buildProfileApiParam () | |
Build the profile api param definitions. | |
buildSearchEngine (array $params=null) | |
Build the search engine to use. | |
getContext () | |
getSearchProfileParams () | |
Variables | |
trait | SearchApi |
Traits for API components that use a SearchEngine. | |
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. http://www.gnu.org/copyleft/gpl.html
Definition in file SearchApi.php.
buildCommonApiParams | ( | $isScrollable = true | ) |
The set of api parameters that are shared between api calls that call the SearchEngine.
Primarily this defines parameters that are utilized by self::buildSearchEngine().
bool | $isScrollable | True if the api offers scrolling |
Definition at line 46 of file SearchApi.php.
References $params, and(), buildProfileApiParam(), ApiBase\LIMIT_BIG1, ApiBase\LIMIT_BIG2, NS_MAIN, ApiBase\PARAM_DFLT, ApiBase\PARAM_HELP_MSG, ApiBase\PARAM_ISMULTI, ApiBase\PARAM_MAX, ApiBase\PARAM_MAX2, ApiBase\PARAM_MIN, ApiBase\PARAM_REQUIRED, and ApiBase\PARAM_TYPE.
Referenced by ApiOpenSearch\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), and ApiQuerySearch\getAllowedParams().
|
private |
Build the profile api param definitions.
Makes bold assumption only one search engine is available, ensure that is true before calling.
Definition at line 102 of file SearchApi.php.
References $params, and(), getContext(), getSearchProfileParams(), ApiBase\PARAM_DFLT, ApiBase\PARAM_HELP_MSG, ApiBase\PARAM_HELP_MSG_PER_VALUE, and ApiBase\PARAM_TYPE.
Referenced by buildCommonApiParams().
Build the search engine to use.
If $params is provided then the following searchEngine options will be set:
string[] | null | $params | API request params (must be sanitized by ApiBase::extractRequestParams() before) |
Definition at line 150 of file SearchApi.php.
References $params, $type, and(), and getSearchProfileParams().
Referenced by ApiQueryPrefixSearch\run(), ApiQuerySearch\run(), and ApiOpenSearch\search().
|
abstract |
Referenced by Action\addHelpLink(), OutputPage\addSubtitle(), SkinTemplate\buildContentNavigationUrls(), SkinTemplate\buildNavUrls(), buildProfileApiParam(), ApiStructureTest\checkMessage(), ActionTest\dummyActionCallback(), TimelessTemplate\execute(), ApiQueryRevisionsBase\extractDeprecatedContent(), ContribsPager\formatRow(), SpecialPage\getConfig(), ResourceLoaderClientHtml\getData(), ImageListPager\getForm(), SpecialPage\getFullTitle(), OutputPage\getHeadLinksArray(), OutputPage\getJSVars(), Action\getLanguage(), SpecialPage\getLanguage(), Action\getOutput(), SpecialPage\getOutput(), Action\getRequest(), SpecialPage\getRequest(), Action\getSkin(), SpecialPage\getSkin(), NewFilesPager\getStartBody(), HTMLForm\getTitle(), BaseTemplate\getTrail(), Action\getUser(), SpecialPage\getUser(), OutputPage\headElement(), Profiler\logData(), Action\msg(), SpecialPage\msg(), SkinTemplate\outputPage(), OutputPage\parserOptions(), SkinTemplate\prepareQuickTemplate(), OutputPage\setHTMLTitle(), OutputPage\setPageTitle(), OutputPage\setTitle(), ActionTest\setUp(), SkinTemplate\tabAction(), ActionTest\testActionFactory(), ActionTest\testCanExecute(), ActionTest\testCanExecuteNoRight(), ActionTest\testCanExecuteRequiresUnblock(), ActionTest\testDisabledAction_isNotResolved(), ActionTest\testGetActionName(), ActionTest\testGetActionName_editredlinkWorkaround(), ActionTest\testGetActionName_historysubmitWorkaround(), ActionTest\testGetActionName_revisiondeleteWorkaround(), and ActionTest\testNull_defaultsToView().
|
abstract |
Referenced by buildProfileApiParam(), and buildSearchEngine().