{ "info": { "author": "Bert Vanderbauwhede", "author_email": "batlock666@gmail.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": ".. contents::\n\n\nInstallation\n============\n\nInstall the distribution from source::\n\n $ python setup.py install\n\nOr install with ``easy_install``::\n\n $ easy_install fnord.easycodec\n\n\nUsage\n=====\n\nThis package can be used to easily create and register codecs.\n\nUse the decorator ``encoder`` to create an encode-function::\n\n >>> from fnord.easycodec import encoder\n >>> @encoder(\"my_codec\")\n ... def my_encode(message):\n ... ...\n\n(``my_codec`` is the name of the codec.)\n\nUse the decorator ``decoder`` to create a decode-function::\n\n >>> from fnord.easycodec import decoder\n >>> @decoder(\"my_codec\")\n ... def my_decode(message):\n ... ...\n\nUse the factory ``CodecRegistration`` to create an object that can be\nreturned by a codec's search-function::\n\n >>> from fnord.easycodec import CodecRegistration, AUTO\n >>> registration = CodecRegistration(\n ... \"my_codec\", my_encode, my_decode,\n ... streamwriter=AUTO, streamreader=AUTO)\n\nThis factory takes the following parameters:\n\n:``name``: The name of the codec. Required.\n:``encode``: The encode-function. Required.\n:``decode``: The decode-function. Required.\n:``incrementalencoder``: The incremental encoder. Optional.\n:``incrementaldecoder``: The incremental decoder. Optional.\n:``streamwriter``: The stream-writer. Optional.\n:``streamreader``: The stream-reader. Optional.\n\nIf one of the optional parameters has the value ``AUTO`` assigned, an\nappropriate object will be generated and used.\n\nUse the factory ``CodecSearch`` to create a search-function for a codec. The\nparameters are the same as for ``CodecRegistration``::\n\n >>> from fnord.easycodec import CodecSearch\n >>> search = CodecSearch(\n ... \"my_codec\", my_encode, my_decode,\n ... streamwriter=AUTO, streamreader=AUTO)\n\nThis function can then be used to register the codec::\n\n >>> import codecs\n >>> codecs.register(search)\n\nContributors\n============\n\n- Bert Vanderbauwhede , Author\n\nChangelog\n=========\n\n\n0.2 (2013-08-17)\n----------------\n\n- Fixed parameters to constructor for exception UnicodeDecodeError\n [Bert Vanderbauwhede]\n\n\n0.1 (2013-08-11)\n----------------\n\n- Package created using templer [Bert Vanderbauwhede]\n- First implementation [Bert Vanderbauwhede]", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/batlock666/fnord.easycodec", "keywords": "codec", "license": "lgpl", "maintainer": null, "maintainer_email": null, "name": "fnord.easycodec", "package_url": "https://pypi.org/project/fnord.easycodec/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/fnord.easycodec/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/batlock666/fnord.easycodec" }, "release_url": "https://pypi.org/project/fnord.easycodec/0.2/", "requires_dist": null, "requires_python": null, "summary": "Tools to create and register codecs.", "version": "0.2" }, "last_serial": 842368, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "2aa0d19f124218801303566fa05deba0", "sha256": "f2c675a51a77de371d1b96b1d8438c4c7b6283394227eac0fa27d0aadf10ac45" }, "downloads": -1, "filename": "fnord.easycodec-0.1.tar.gz", "has_sig": false, "md5_digest": "2aa0d19f124218801303566fa05deba0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6779, "upload_time": "2013-08-11T18:51:04", "url": "https://files.pythonhosted.org/packages/6d/cb/38df5d08cd6b1e7e3d50eb23837fdf0bed524a228828818ec42365d5f3cf/fnord.easycodec-0.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "46269f2dce6ace9055337d3a4434e9df", "sha256": "a2c6dfa48b621c3fb779ab78adc68b170d90b6aceece05e92f605d52dfee6fdc" }, "downloads": -1, "filename": "fnord.easycodec-0.2.tar.gz", "has_sig": false, "md5_digest": "46269f2dce6ace9055337d3a4434e9df", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6831, "upload_time": "2013-08-17T20:09:22", "url": "https://files.pythonhosted.org/packages/5a/c9/8df1c0f4d3ca7db965156585001544c04dabecb89875abcdee8bed930f62/fnord.easycodec-0.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "46269f2dce6ace9055337d3a4434e9df", "sha256": "a2c6dfa48b621c3fb779ab78adc68b170d90b6aceece05e92f605d52dfee6fdc" }, "downloads": -1, "filename": "fnord.easycodec-0.2.tar.gz", "has_sig": false, "md5_digest": "46269f2dce6ace9055337d3a4434e9df", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6831, "upload_time": "2013-08-17T20:09:22", "url": "https://files.pythonhosted.org/packages/5a/c9/8df1c0f4d3ca7db965156585001544c04dabecb89875abcdee8bed930f62/fnord.easycodec-0.2.tar.gz" } ] }