multi-byte character string decoder
Project description
Summary
mbstrdecoder is a Python library for multi-byte character string decoder.
Installation
Install from PyPI
pip install mbstrdecoder
Install from PPA (for Ubuntu)
sudo add-apt-repository ppa:thombashi/ppa sudo apt update sudo apt install python3-mbstrdecoder
Usage
- Sample Code:
from mbstrdecoder import MultiByteStrDecoder encoded_multibyte_text = "マルチバイト文字".encode("utf-8") decoder = MultiByteStrDecoder(encoded_multibyte_text) print("encoded bytes: {}".format(encoded_multibyte_text)) print("unicode: {}".format(decoder.unicode_str)) print("codec: {}".format(decoder.codec))
- Output:
encoded bytes: b'\xe3\x83\x9e\xe3\x83\xab\xe3\x83\x81\xe3\x83\x90\xe3\x82\xa4\xe3\x83\x88\xe6\x96\x87\xe5\xad\x97' unicode: マルチバイト文字 codec: utf_8
Dependencies
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mbstrdecoder-1.0.1.tar.gz
(10.6 kB
view details)
Built Distribution
File details
Details for the file mbstrdecoder-1.0.1.tar.gz
.
File metadata
- Download URL: mbstrdecoder-1.0.1.tar.gz
- Upload date:
- Size: 10.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f895e1fb97496855ab5e43de99588787169c01f782c71625142d1a62729e9f9d |
|
MD5 | aa377cfa117318583dffa1fd96123bdf |
|
BLAKE2b-256 | b73b2524dd4771dfca572269036fb08356715cb78a1c1c2a4dae3a810a86b777 |
File details
Details for the file mbstrdecoder-1.0.1-py3-none-any.whl
.
File metadata
- Download URL: mbstrdecoder-1.0.1-py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 56b967800d6554815a6b18f98f915e84912852eff21d94d5e036fe124bc27f53 |
|
MD5 | 40fee1d0b2aae3c8ea69f96ff565551c |
|
BLAKE2b-256 | e8f60e6bb50c3c6380a4982c87d80e70b2f6e366523a57a0c58594aea472206d |