X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/5e5addcdbf20022b3fd76dc8c2275a1eecf12a3c..16daa57e4757e4daeffec1e61630f989727dc563:/nominatim/tokenizer/base.py diff --git a/nominatim/tokenizer/base.py b/nominatim/tokenizer/base.py index e126507b..53289c78 100644 --- a/nominatim/tokenizer/base.py +++ b/nominatim/tokenizer/base.py @@ -149,11 +149,14 @@ class AbstractTokenizer(ABC): @abstractmethod - def init_from_project(self) -> None: + def init_from_project(self, config: Configuration) -> None: """ Initialise the tokenizer from an existing database setup. The function should load all previously saved configuration from the project directory and/or the property table. + + Arguments: + config: Read-only object with configuration options. """ pass @@ -187,7 +190,7 @@ class AbstractTokenizer(ABC): @abstractmethod - def check_database(self) -> str: + def check_database(self, config: Configuration) -> str: """ Check that the database is set up correctly and ready for being queried. @@ -196,6 +199,9 @@ class AbstractTokenizer(ABC): description of the issue as well as hints for the user on how to resolve the issue. + Arguments: + config: Read-only object with configuration options. + Return `None`, if no issue was found. """ pass