colrev.package_manager.package_base_classes.SearchSourcePackageBaseClass
- class colrev.package_manager.package_base_classes.SearchSourcePackageBaseClass(*, search_file, logger=None, verbose_mode=False)[source]
Bases:
ABCThe base class for SearchSource packages
The following cli commands call specific methods of a SearchSource package:
colrev search --add package_name-> callspackage.add_endpoint()colrev search-> callssearchoperation -> callspackage.search()colrev load-> callsloadoperation -> callspackage.load()colrev prep-> callsprepoperation -> callspackage.prep()Methods
add_endpointAdd the SearchSource as an endpoint.
ensure_append_onlyEnsure that the SearchSource is append-only (override this method if needed).
heuristicHeuristic to identify which SearchSource a search file belongs to.
loadLoad records from the SearchSource.
prep_link_mdRetrieve masterdata from the SearchSource.
prepareRun the custom source-prep operation.
searchRun a search of the SearchSource.
Attributes
CURRENT_SYNTAX_VERSIONci_supportedsource_identifiersearch_typesheuristic_statussearch_source- abstract classmethod add_endpoint(params, path, logger=None)[source]
Add the SearchSource as an endpoint.
- Return type:
- classmethod ensure_append_only(filename)[source]
Ensure that the SearchSource is append-only (override this method if needed).
- Return type:
bool
- abstract classmethod heuristic(filename, data)[source]
Heuristic to identify which SearchSource a search file belongs to.
- Return type:
dict