How to use the schwifty.registry function in schwifty

To help you get started, we’ve selected a few schwifty examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mdomke / schwifty / schwifty / bic.py View on Github external
def _lookup_values(self, key):
        entries = registry.get("bic").get(self.compact, [])
        return sorted({entry[key] for entry in entries})
github mdomke / schwifty / schwifty / iban.py View on Github external
def _get_iban_spec(country_code):
    try:
        return registry.get("iban")[country_code]
    except KeyError:
        raise ValueError("Unknown country-code '{}'".format(country_code))
github mdomke / schwifty / schwifty / bic.py View on Github external
def exists(self):
        """bool: Indicates if the BIC is available in Schwifty's registry."""
        return bool(registry.get("bic").get(self.compact))