Teks sumber — English
Terjemahan — Bahasa Indonesia
Unregister a codec search function and clear the registry's cache. If the search function is not registered, do nothing. Return 0 on success. Raise an exception and return -1 on error.
Return ``1`` or ``0`` depending on whether there is a registered codec for the given *encoding*. This function always succeeds.
In the following functions, the *encoding* string is looked up converted to all lower-case characters, which makes encodings looked up through this mechanism effectively case-insensitive. If no codec is found, a :exc:`LookupError` is set and ``NULL`` returned.
The callback gets a single argument, an instance of :exc:`UnicodeEncodeError`, :exc:`UnicodeDecodeError` or :exc:`UnicodeTranslateError` that holds information about the problematic sequence of characters or bytes and their offset in the original string (see :ref:`unicodeexceptions` for functions to extract this information). The callback must either raise the given exception, or return a two-item tuple containing the replacement for the problematic sequence, and an integer giving the offset in the original string at which encoding/decoding should be resumed.
Return ``0`` on success, ``-1`` on error.
Mengembalikan ``0`` jika berhasil, ``-1`` jika eror.
Lookup the error handling callback function registered under *name*. As a special case ``NULL`` can be passed, in which case the error handling callback for "strict" will be returned.