binhex
index
/usr/lib/python1.5/binhex.py
 

binhex - Macintosh binhex compression/decompression
easy interface:
binhex(inputfilename, outputfilename)
hexbin(inputfilename, outputfilename)

   
Modules
                        
binascii
os
string
struct
sys

   
Classes
                        
BinHex
FInfo
HexBin
_Hqxcoderengine
_Hqxdecoderengine
_Rlecoderengine
_Rledecoderengine
openrsrc

   
class BinHex
              
__init__(self, (name, finfo, dlen, rlen), ofp)
_write(self, data)
_writecrc(self)
_writeinfo(self, name, finfo)
close(self)
close_data(self)
write(self, data)
write_rsrc(self, data)

   
class FInfo
              
__init__(self)

   
class HexBin
              
__init__(self, ifp)
_checkcrc(self)
_read(self, len)
_readheader(self)
close(self)
close_data(self)
read(self, *n)
read_rsrc(self, *n)

   
class _Hqxcoderengine
            Write data to the coder in 3-byte chunks
              
__init__(self, ofp)
_flush(self, force)
close(self)
write(self, data)

   
class _Hqxdecoderengine
            Read data via the decoder in 4-byte chunks
              
__init__(self, ifp)
close(self)
read(self, totalwtd)
Read at least wtd bytes (or until EOF)

   
class _Rlecoderengine
            Write data to the RLE-coder in suitably large chunks
              
__init__(self, ofp)
close(self)
write(self, data)

   
class _Rledecoderengine
            Read data via the RLE-coder
              
__init__(self, ifp)
_fill(self, wtd)
close(self)
read(self, wtd)

   
class openrsrc
              
__init__(self, *args)
close(self)
read(self, *args)
write(self, *args)

   
Constants
                        
Error = 'binhex.Error'
LINELEN = 64
REASONABLY_LARGE = 32768
RUNCHAR = '\220'