python的巴西基本词汇
brasil.vocab的Python项目详细描述
目录
Vocabularies available
Geographic information
- 国家(巴西葡萄牙语为ISO 3166)
- 州(巴西州)
- 城市(巴西城市,按州组织)
- 城市(巴西城市)
Telecom information
- 区号(地理代码a.k.a ddd)
- 非地理代码(0x00前缀)
- 代码(地理+非地理代码)
Requirements
- Python 2.4
Installation
在python包上安装:
easy_install brasil.vocab
将其添加到安装需要在另一个python包中(在setup.py中):
install_requires=[ 'setuptools', # -*- Extra requirements: -*- 'brasil.vocab' ],
Basic usage
安装后,我们只需导入并使用:
>>> from brasil.vocab.geo import uf >>> len(uf) 27 >>> print uf[0] ('AC', u'Acre')
Credits
- Simples Consultoria (products at simplesconsultoria dot com dot br) - Implementation
Changelog
0.8 (2011-12-20)
- Added tests [ericof]
- Added codes vocabulary to telecom (cng + ddd)[ericof]
- Added cng vocabulary to telecom [ericof]
- DDD vocabulary now do not provide cng prefixes (0x00) [ericof]
0.7 (2011-05-26)
- Fixing typo in Cities vocabulary [erico_andrei]
0.6 (2011-05-25)
- Fixing Cities vocabularies [erico_andrei]
0.5 (2011-05-24)
- Countries [erico_andrei]
- Brazilian States and Cities [lepri]
- Initial implementation [erico_andrei]
- Area Codes [erico_andrei]