Back to index

python3.2  3.2.2
Public Member Functions | Public Attributes
tarfile._StreamProxy Class Reference
Inheritance diagram for tarfile._StreamProxy:
Inheritance graph
Collaboration diagram for tarfile._StreamProxy:
Collaboration graph

List of all members.

Public Member Functions

def __init__
def read
def getcomptype
def close

Public Attributes

_PyObject_HEAD_EXTRA Py_ssize_t ob_refcnt
struct _typeobjectob_type

Detailed Description

Small proxy class that enables transparent compression
   detection for the Stream interface (mode 'r|*').

Definition at line 611 of file

Constructor & Destructor Documentation

def tarfile._StreamProxy.__init__ (   self,

Definition at line 616 of file

00617     def __init__(self, fileobj):
00618         self.fileobj = fileobj
00619         self.buf =

Here is the caller graph for this function:

Member Function Documentation

Definition at line 631 of file

00632     def close(self):
00633         self.fileobj.close()
00634 # class StreamProxy

Here is the caller graph for this function:

Definition at line 624 of file

00625     def getcomptype(self):
00626         if self.buf.startswith(b"\037\213\010"):
00627             return "gz"
00628         if self.buf.startswith(b"BZh91"):
00629             return "bz2"
00630         return "tar"

def (   self,

Definition at line 620 of file

00621     def read(self, size):
00622 =
00623         return self.buf

Here is the caller graph for this function:

Member Data Documentation

Definition at line 618 of file

Definition at line 617 of file

Definition at line 107 of file object.h.

struct _typeobject* _object::ob_type [inherited]

Definition at line 108 of file object.h.

Definition at line 621 of file

The documentation for this class was generated from the following file: