Package svnmailer :: Module stream :: Class UnicodeStream
[show private | hide private]
[frames | no frames]

Class UnicodeStream

 object --+    
          |    
_BaseStream --+
              |
             UnicodeStream


Stream wrapper, which accepts unicode and a specified charset
Method Summary
  __init__(self, stream, in_enc, out_enc, errors)
Initialization
  write(self, towrite)
Write a string or unicode
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name...
  __getattribute__(...)
x.__getattribute__('name') <==> x.name...
  __hash__(x)
x.__hash__() <==> hash(x)...
  __reduce__(...)
helper for pickle...
  __reduce_ex__(...)
helper for pickle...
  __repr__(x)
x.__repr__() <==> repr(x)...
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value...
  __str__(x)
x.__str__() <==> str(x)...
    Inherited from type
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T...

Instance Variable Summary
callable decode: Decoder function for the input encoding
str err: error handling advise

Method Details

__init__(self, stream, in_enc='utf-8', out_enc='utf-8', errors='replace')
(Constructor)

Initialization
Parameters:
stream - The stream to wrap
           (type=file)
in_enc - The input encoding, that should be assumed, if a pure string is written
           (type=str)
out_enc - The output encoding
           (type=str)
errors - The error handling indicator, when an unicode error occurs. (The default is quite lenient and writes replace characters on errors)
           (type=str)
Overrides:
svnmailer.stream._BaseStream.__init__

write(self, towrite)

Write a string or unicode
Overrides:
svnmailer.stream._BaseStream.write

Instance Variable Details

decode

Decoder function for the input encoding
Type:
callable

err

error handling advise
Type:
str

Generated by Epydoc 2.0 on Sun Sep 25 20:49:10 2005 http://epydoc.sf.net