{
    "mode": "pydoc",
    "parameter": "_codecs",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/pydoc/_codecs/json",
    "generated": "2026-06-02T17:51:05Z",
    "sections": {
        "NAME": {
            "content": "codecs\n",
            "subsections": []
        },
        "FUNCTIONS": {
            "content": "",
            "subsections": [
                {
                    "name": "ascii_decode",
                    "content": ""
                },
                {
                    "name": "ascii_encode",
                    "content": ""
                },
                {
                    "name": "charmap_build",
                    "content": ""
                },
                {
                    "name": "charmap_decode",
                    "content": ""
                },
                {
                    "name": "charmap_encode",
                    "content": ""
                },
                {
                    "name": "decode",
                    "content": "Decodes obj using the codec registered for encoding.\n\nDefault encoding is 'utf-8'.  errors may be given to set a\ndifferent error handling scheme.  Default is 'strict' meaning that encoding\nerrors raise a ValueError.  Other possible values are 'ignore', 'replace'\nand 'backslashreplace' as well as any other name registered with\ncodecs.registererror that can handle ValueErrors.\n"
                },
                {
                    "name": "encode",
                    "content": "Encodes obj using the codec registered for encoding.\n\nThe default encoding is 'utf-8'.  errors may be given to set a\ndifferent error handling scheme.  Default is 'strict' meaning that encoding\nerrors raise a ValueError.  Other possible values are 'ignore', 'replace'\nand 'backslashreplace' as well as any other name registered with\ncodecs.registererror that can handle ValueErrors.\n"
                },
                {
                    "name": "escape_decode",
                    "content": ""
                },
                {
                    "name": "escape_encode",
                    "content": ""
                },
                {
                    "name": "latin_1_decode",
                    "content": ""
                },
                {
                    "name": "latin_1_encode",
                    "content": ""
                },
                {
                    "name": "lookup",
                    "content": "Looks up a codec tuple in the Python codec registry and returns a CodecInfo object.\n"
                },
                {
                    "name": "lookup_error",
                    "content": "lookuperror(errors) -> handler\n\nReturn the error handler for the specified error handling name or raise a\nLookupError, if no handler exists under this name.\n"
                },
                {
                    "name": "raw_unicode_escape_decode",
                    "content": ""
                },
                {
                    "name": "raw_unicode_escape_encode",
                    "content": ""
                },
                {
                    "name": "readbuffer_encode",
                    "content": ""
                },
                {
                    "name": "register",
                    "content": "Register a codec search function.\n\nSearch functions are expected to take one argument, the encoding name in\nall lower case letters, and either return None, or a tuple of functions\n(encoder, decoder, streamreader, streamwriter) (or a CodecInfo object).\n"
                },
                {
                    "name": "register_error",
                    "content": "Register the specified error handler under the name errors.\n\nhandler must be a callable object, that will be called with an exception\ninstance containing information about the location of the encoding/decoding\nerror and must return a (replacement, new position) tuple.\n"
                },
                {
                    "name": "unicode_escape_decode",
                    "content": ""
                },
                {
                    "name": "unicode_escape_encode",
                    "content": ""
                },
                {
                    "name": "unregister",
                    "content": "Unregister a codec search function and clear the registry's cache.\n\nIf the search function is not registered, do nothing.\n"
                },
                {
                    "name": "utf_16_be_decode",
                    "content": ""
                },
                {
                    "name": "utf_16_be_encode",
                    "content": ""
                },
                {
                    "name": "utf_16_decode",
                    "content": ""
                },
                {
                    "name": "utf_16_encode",
                    "content": ""
                },
                {
                    "name": "utf_16_ex_decode",
                    "content": ""
                },
                {
                    "name": "utf_16_le_decode",
                    "content": ""
                },
                {
                    "name": "utf_16_le_encode",
                    "content": ""
                },
                {
                    "name": "utf_32_be_decode",
                    "content": ""
                },
                {
                    "name": "utf_32_be_encode",
                    "content": ""
                },
                {
                    "name": "utf_32_decode",
                    "content": ""
                },
                {
                    "name": "utf_32_encode",
                    "content": ""
                },
                {
                    "name": "utf_32_ex_decode",
                    "content": ""
                },
                {
                    "name": "utf_32_le_decode",
                    "content": ""
                },
                {
                    "name": "utf_32_le_encode",
                    "content": ""
                },
                {
                    "name": "utf_7_decode",
                    "content": ""
                },
                {
                    "name": "utf_7_encode",
                    "content": ""
                },
                {
                    "name": "utf_8_decode",
                    "content": ""
                },
                {
                    "name": "utf_8_encode",
                    "content": ""
                }
            ]
        },
        "FILE": {
            "content": "(built-in)\n\n",
            "subsections": []
        }
    },
    "summary": "codecs",
    "flags": [],
    "examples": [],
    "see_also": []
}