docs: def add_transcoder(application, transcoder, content_type=None):
      """
      Register a transcoder for a specific content type.
  
      :param tornado.web.Application application: the application to modify
      :param transcoder: object that translates between :class:`bytes` and
          :class:`object` instances
      :param str content_type: the content type to add.  If this is
          unspecified or :data:`None`, then the transcoder's ``content_type``
          attribute is used.
  
      The `transcoder` instance is required to implement the following
      simple protocol:
  
      .. attribute:: transcoder.content_type
  
         :class:`str` that identifies the MIME type that the transcoder
         implements.
  
      .. method:: transcoder.to_bytes(inst_data, encoding=None) -> bytes
  
         :param object inst_data: the object to encode
         :param str encoding: character encoding to apply or :data:`None`
         :returns: the encoded :class:`bytes` instance
  
      .. method:: transcoder.from_bytes(data_bytes, encoding=None) -> object
  
         :param bytes data_bytes: the :class:`bytes` instance to decode
         :param str encoding: character encoding to use or :data:`None`
         :returns: the decoded :class:`object` instance
  
      """
      settings = get_settings(application, force_instance=True)
      settings[content_type or transcoder.content_type] = transcoder