From ed280d5ac360e2af796e9bd973d7b4df89f0c449 Mon Sep 17 00:00:00 2001 From: "Jeremy T. Bouse" Date: Fri, 27 Nov 2009 16:20:12 -0500 Subject: Imported Upstream version 1.7.4 --- docs/paramiko.compress-pysrc.html | 148 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 148 insertions(+) create mode 100644 docs/paramiko.compress-pysrc.html (limited to 'docs/paramiko.compress-pysrc.html') diff --git a/docs/paramiko.compress-pysrc.html b/docs/paramiko.compress-pysrc.html new file mode 100644 index 0000000..47f4de1 --- /dev/null +++ b/docs/paramiko.compress-pysrc.html @@ -0,0 +1,148 @@ + + + + + paramiko.compress + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package paramiko :: + Module compress + + + + + +
[frames] | no frames]
+
+

Source Code for Module paramiko.compress

+
+ 1  # Copyright (C) 2003-2007  Robey Pointer <robey@lag.net> 
+ 2  # 
+ 3  # This file is part of paramiko. 
+ 4  # 
+ 5  # Paramiko is free software; you can redistribute it and/or modify it under the 
+ 6  # terms of the GNU Lesser General Public License as published by the Free 
+ 7  # Software Foundation; either version 2.1 of the License, or (at your option) 
+ 8  # any later version. 
+ 9  # 
+10  # Paramiko is distrubuted in the hope that it will be useful, but WITHOUT ANY 
+11  # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR 
+12  # A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more 
+13  # details. 
+14  # 
+15  # You should have received a copy of the GNU Lesser General Public License 
+16  # along with Paramiko; if not, write to the Free Software Foundation, Inc., 
+17  # 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA. 
+18   
+19  """ 
+20  Compression implementations for a Transport. 
+21  """ 
+22   
+23  import zlib 
+24   
+25   
+
26 -class ZlibCompressor (object): +
27 - def __init__(self): +
28 self.z = zlib.compressobj(9) +
29 +
30 - def __call__(self, data): +
31 return self.z.compress(data) + self.z.flush(zlib.Z_FULL_FLUSH) +
32 +33 +
34 -class ZlibDecompressor (object): +
35 - def __init__(self): +
36 self.z = zlib.decompressobj() +
37 +
38 - def __call__(self, data): +
39 return self.z.decompress(data) +
40 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + -- cgit v1.2.3