Skip to main content

ISO 4217 currency data package for Python

Project description

https://badge.fury.io/py/iso4217.svg? https://github.com/dahlia/iso4217/actions/workflows/main.yaml/badge.svg

This Python package contains ISO 4217 currency data, represented as enum module which was introduced in 3.4. Note that this works on Python 2.7 as well as 3.10, the latest version of Python, through enum34 package.

>>> from iso4217 import Currency
>>> Currency.usd
<Currency.usd: 'USD'>
>>> Currency.usd.code
'USD'
>>> Currency.usd.currency_name
'US Dollar'
>>> Currency.usd.exponent  # USD has cents
2
>>> Currency.jpy
<Currency.jpy: 'JPY'>
>>> Currency.jpy.currency_name
'Yen'
>>> Currency.jpy.exponent  # JPY has no minor units
0
>>> Currency('KRW')  # Get by the code string
<Currency.krw: 'KRW'>
>>> Currency.krw is Currency('KRW')
True

Written by Hong Minhee. Distributed under Public Domain.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iso4217-1.9.20220401.tar.gz (12.4 kB view details)

Uploaded Source

Built Distribution

iso4217-1.9.20220401-py2.py3-none-any.whl (10.5 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file iso4217-1.9.20220401.tar.gz.

File metadata

  • Download URL: iso4217-1.9.20220401.tar.gz
  • Upload date:
  • Size: 12.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.2

File hashes

Hashes for iso4217-1.9.20220401.tar.gz
Algorithm Hash digest
SHA256 e4c954a0c42e42a064cc226781cde39f88fe056959a391e2367c5e544d3107d2
MD5 b08c8adec56dee906a07cb71fcbf7747
BLAKE2b-256 65216edb9f535b4871904cd51107e61f1791efee31f9870002b31f7e31b266e8

See more details on using hashes here.

File details

Details for the file iso4217-1.9.20220401-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for iso4217-1.9.20220401-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 53fe16e85bfa69b5af8345811179174e7f549918b33069f2cc7329d910e4b202
MD5 39c81609cbf539e69d5714411a3f76a7
BLAKE2b-256 dd4fe866176ec9db1d2c30599446f2d985cd83ccc2b2622a6472175bb78d3a7d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page