Search

class OC\Search
Provide an interface to all search providers
Source:lib/private/Search.php#38
Implements:OCP\ISearch

Properties

Methods

public OC\Search::searchPaged($query, $inApps=[], $page=1, $size=30)
Search all providers for $query
Source:

lib/private/Search.php#51

Parameters:
  • $query (string)
  • $inApps (string[]) optionally limit results to the given apps
  • $page (int) pages start at page 1
Returns:

array An array of OC\Search\Result’s

public OC\Search::clearProviders()
Remove all registered search providers
Source:lib/private/Search.php#78
public OC\Search::removeProvider($provider)
Remove one existing search provider
Source:

lib/private/Search.php#87

Parameters:
  • $provider (string) class name of a OCSearchProvider
public OC\Search::registerProvider($class, $options=[])
Register a new search provider to search with
Source:

lib/private/Search.php#103

Parameters:
  • $class (string) class name of a OCSearchProvider
  • $options (array) optional