harmonize interface of token analysis module

The configure() function now receives a Transliterator object instead
of the ICU rules. This harmonizes the parameters with the create
function.
This commit is contained in:
Sarah Hoffmann
2022-07-29 10:43:07 +02:00
parent f0d640961a
commit c8873d34af
8 changed files with 34 additions and 24 deletions

View File

@@ -8,13 +8,13 @@
Specialized processor for postcodes. Supports a 'lookup' variant of the
token, which produces variants with optional spaces.
"""
from typing import Mapping, Any, List
from typing import Any, List
from nominatim.tokenizer.token_analysis.generic_mutation import MutationVariantGenerator
### Configuration section
def configure(rules: Mapping[str, Any], normalization_rules: str) -> None: # pylint: disable=W0613
def configure(*_: Any) -> None:
""" All behaviour is currently hard-coded.
"""
return None