IFullTextSearchManager

interface OCP\FullTextSearch\IFullTextSearchManager
Interface IFullTextSearchManager
Should be used to manage FullTextSearch from the app that contains your
Content Provider/Search Platform.
Implemented by:OC\FullTextSearch\FullTextSearchManager
Source:lib/public/FullTextSearch/IFullTextSearchManager.php#44

Methods

public OCP\FullTextSearch\IFullTextSearchManager::registerProviderService($providerService)
Register a IProviderService.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#54

Parameters:
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::registerIndexService($indexService)
Register a IIndexService.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#63

Parameters:
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::registerSearchService($searchService)
Register a ISearchService.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#72

Parameters:
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::isAvailable()
returns true is Full Text Search is available (app is present and Service
are registered)
Source:lib/public/FullTextSearch/IFullTextSearchManager.php#82
Since:16.0.0
Returns:bool
public OCP\FullTextSearch\IFullTextSearchManager::addJavascriptAPI()
Add the Javascript API in the navigation page of an app.
Needed to replace the default search.
Source:lib/public/FullTextSearch/IFullTextSearchManager.php#91
Since:15.0.0
public OCP\FullTextSearch\IFullTextSearchManager::isProviderIndexed($providerId)
Check if the provider $providerId is already indexed.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#103

Parameters:
  • $providerId (string)
Since:

15.0.0

Returns:

bool

public OCP\FullTextSearch\IFullTextSearchManager::getIndex($providerId, $documentId)
Retrieve an Index from the database, based on the Id of the Provider
and the Id of the Document
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#117

Parameters:
  • $providerId (string)
  • $documentId (string)
Since:

15.0.0

Returns:

\OCP\FullTextSearch\Model\IIndex

public OCP\FullTextSearch\IFullTextSearchManager::createIndex($providerId, $documentId, $userId, $status=0)
Create a new Index.
This method must be called when a new document is created.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#134

Parameters:
  • $providerId (string)
  • $documentId (string)
  • $userId (string)
  • $status (int)
Since:

15.0.0

Returns:

\OCP\FullTextSearch\Model\IIndex

public OCP\FullTextSearch\IFullTextSearchManager::updateIndexStatus($providerId, $documentId, $status, $reset=false)
Update the status of an Index. status is a bitflag, setting $reset to
true will reset the status to the value defined in the parameter.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#148

Parameters:
  • $providerId (string)
  • $documentId (string)
  • $status (int)
  • $reset (bool)
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::updateIndexesStatus($providerId, $documentIds, $status, $reset=false)
Update the status of an array of Index. status is a bit flag, setting $reset to
true will reset the status to the value defined in the parameter.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#162

Parameters:
  • $providerId (string)
  • $documentIds (array)
  • $status (int)
  • $reset (bool)
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::updateIndexes($indexes)
Update an array of Index.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#171

Parameters:
Since:

15.0.0

public OCP\FullTextSearch\IFullTextSearchManager::search($request, $userId="")
Search using an array as request. If $userId is empty, will use the
current session.
Source:

lib/public/FullTextSearch/IFullTextSearchManager.php#185

Parameters:
  • $request (array)
  • $userId (string)
See:

\OCP\FullTextSearch\ISearchService::generateSearchRequest

Since:

15.0.0

Returns:

\OCP\FullTextSearch\Model\ISearchResult[]