reviewboard.search.search_backends.registry¶
The search engine backend registry.
- class SearchBackendRegistry[source]¶
Bases:
Registry
A registry for search engines backends.
Extensions can add support for additional search engine backends.
See the registry documentation for information on how registries work.
- lookup_attrs: Sequence[str] = ['search_backend_id'][source]¶
A list of attributes that items can be looked up by.
- get_search_backend(search_backend_id)[source]¶
Return the search backend with the specified ID.
- Parameters:
search_backend_id (
unicode
) – The unique identifier of the search engine.- Returns:
The search engine class, if it could be found. Otherwise,
None
.- Return type:
reviewboard.search.search_engines.base.SearchBackend
- get_defaults()[source]¶
Return the default search backends.
- Returns:
The default search backends to use.
- Return type:
list
ofreviewboard.search.search_backends.base.SearchBackend
- __annotations__ = {'_items': 'Set[RegistryItemType]', '_populated': 'bool', '_registry': 'Dict[str, Dict[object, RegistryItemType]]', 'already_registered_error_class': 'Type[AlreadyRegisteredError]', 'default_errors': 'RegistryErrorsDict', 'errors': 'RegistryErrorsDict', 'item_name': 'Optional[str]', 'lookup_attrs': 'Sequence[str]', 'lookup_error_class': 'Type[ItemLookupError]'}¶
- __parameters__ = ()¶