Skip to main content

multi-byte character string decoder

Project description

mbstrdecoder

https://badge.fury.io/py/mbstrdecoder.svg https://img.shields.io/pypi/pyversions/mbstrdecoder.svg https://img.shields.io/travis/thombashi/mbstrdecoder/master.svg?label=Linux/macOS https://img.shields.io/appveyor/ci/thombashi/mbstrdecoder/master.svg?label=Windows https://coveralls.io/repos/github/thombashi/mbstrdecoder/badge.svg?branch=master

Summary

Python library for multi-byte character string decoder.

Installation

pip install mbstrdecoder

Usage

Sample Code:
from __future__ import print_function
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

Python 2.7+ or 3.4+

Test dependencies

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

mbstrdecoder-0.5.1.tar.gz (7.4 kB view details)

Uploaded Source

Built Distribution

mbstrdecoder-0.5.1-py2.py3-none-any.whl (6.4 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file mbstrdecoder-0.5.1.tar.gz.

File metadata

  • Download URL: mbstrdecoder-0.5.1.tar.gz
  • Upload date:
  • Size: 7.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for mbstrdecoder-0.5.1.tar.gz
Algorithm Hash digest
SHA256 92b22a773f040bf97380d7537dc2f7d6de90ce25e213f3a755654eaa844f3d02
MD5 4da9e3f49ea9c43d0f491a05547d05ea
BLAKE2b-256 ee119b33bf6a6cb920dbfdcc9cc0697b5224c2c4145a5d4fae493322e6f9a9d9

See more details on using hashes here.

File details

Details for the file mbstrdecoder-0.5.1-py2.py3-none-any.whl.

File metadata

  • Download URL: mbstrdecoder-0.5.1-py2.py3-none-any.whl
  • Upload date:
  • Size: 6.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for mbstrdecoder-0.5.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 49c6709a2ac03a28d9a7c079145bce52097399792bdf052ffee5d31482bc9561
MD5 f8b963a51b68add99c701d77a939b7e1
BLAKE2b-256 63b55a0e808eaf3b998965fea353de69fad37626fd24d462ff052555fe599d30

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