[Python-checkins] python/dist/src/Lib/email Charset.py,1.6,1.7

barry@users.sourceforge.net barry@users.sourceforge.net
Mon, 30 Sep 2002 17:02:36 -0700


Update of /cvsroot/python/python/dist/src/Lib/email
In directory usw-pr-cvs1:/tmp/cvs-serv28660

Modified Files:
	Charset.py 
Log Message:
Docstring consistency with the updated .tex files.


Index: Charset.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/email/Charset.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** Charset.py	28 Sep 2002 17:47:56 -0000	1.6
--- Charset.py	1 Oct 2002 00:02:33 -0000	1.7
***************
*** 86,90 ****
  # Convenience functions for extending the above mappings
  def add_charset(charset, header_enc=None, body_enc=None, output_charset=None):
!     """Add charset properties to the global map.
  
      charset is the input character set, and must be the canonical name of a
--- 86,90 ----
  # Convenience functions for extending the above mappings
  def add_charset(charset, header_enc=None, body_enc=None, output_charset=None):
!     """Add character set properties to the global registry.
  
      charset is the input character set, and must be the canonical name of a
***************
*** 105,109 ****
      Both input_charset and output_charset must have Unicode codec entries in
      the module's charset-to-codec mapping; use add_codec(charset, codecname)
!     to add codecs the module does not know about.  See the codec module's
      documentation for more information.
      """
--- 105,109 ----
      Both input_charset and output_charset must have Unicode codec entries in
      the module's charset-to-codec mapping; use add_codec(charset, codecname)
!     to add codecs the module does not know about.  See the codecs module's
      documentation for more information.
      """
***************
*** 127,131 ****
      charset is the canonical name of a character set.  codecname is the name
      of a Python codec, as appropriate for the second argument to the unicode()
!     built-in, or to the .encode() method of a Unicode string.
      """
      CODEC_MAP[charset] = codecname
--- 127,131 ----
      charset is the canonical name of a character set.  codecname is the name
      of a Python codec, as appropriate for the second argument to the unicode()
!     built-in, or to the encode() method of a Unicode string.
      """
      CODEC_MAP[charset] = codecname
***************
*** 139,144 ****
      for a specific character set.  It also provides convenience routines for
      converting between character sets, given the availability of the
!     applicable codecs.  Given an character set, it will do its best to provide
!     information on how to use that character set in an email.
  
      Certain character sets must be encoded with quoted-printable or base64
--- 139,145 ----
      for a specific character set.  It also provides convenience routines for
      converting between character sets, given the availability of the
!     applicable codecs.  Given a character set, it will do its best to provide
!     information on how to use that character set in an email in an
!     RFC-compliant way.
  
      Certain character sets must be encoded with quoted-printable or base64
***************
*** 210,214 ****
          the encoding used, or it is a function in which case you should call
          the function with a single argument, the Message object being
!         encoded.  The function should then set the Content-Transfer-Encoding:
          header itself to whatever is appropriate.
  
--- 211,215 ----
          the encoding used, or it is a function in which case you should call
          the function with a single argument, the Message object being
!         encoded.  The function should then set the Content-Transfer-Encoding
          header itself to whatever is appropriate.
  
***************
*** 236,243 ****
  
          Uses the input_codec to try and convert the string to Unicode, so it
!         can be safely split on character boundaries (even for double-byte
          characters).
  
!         Returns the string untouched if we don't know how to convert it to
          Unicode with the input_charset.
  
--- 237,244 ----
  
          Uses the input_codec to try and convert the string to Unicode, so it
!         can be safely split on character boundaries (even for multibyte
          characters).
  
!         Returns the string as-is if it isn't known how to convert it to
          Unicode with the input_charset.
  
***************
*** 257,264 ****
          """Convert a splittable string back into an encoded string.
  
!         Uses the proper codec to try and convert the string from
!         Unicode back into an encoded format.  Return the string as-is
!         if it is not Unicode, or if it could not be encoded from
!         Unicode.
  
          Characters that could not be converted from Unicode will be replaced
--- 258,264 ----
          """Convert a splittable string back into an encoded string.
  
!         Uses the proper codec to try and convert the string from Unicode back
!         into an encoded format.  Return the string as-is if it is not Unicode,
!         or if it could not be converted from Unicode.
  
          Characters that could not be converted from Unicode will be replaced
***************
*** 283,287 ****
          """Return the output character set.
  
!         This is self.output_charset if that is set, otherwise it is
          self.input_charset.
          """
--- 283,287 ----
          """Return the output character set.
  
!         This is self.output_charset if that is not None, otherwise it is
          self.input_charset.
          """