Back to index

obnam  1.1
Public Member Functions | Private Attributes
obnamlib.plugins.backup_plugin.ChunkidPool Class Reference

List of all members.

Public Member Functions

def __init__
def add
def __contains__
def get
def clear
def __iter__

Private Attributes

 _mapping

Detailed Description

Checksum/chunkid mappings that are pending an upload to shared trees.

Definition at line 31 of file backup_plugin.py.


Constructor & Destructor Documentation

Definition at line 35 of file backup_plugin.py.

00035 
00036     def __init__(self):
00037         self.clear()
        

Here is the call graph for this function:


Member Function Documentation

Definition at line 43 of file backup_plugin.py.

00043 
00044     def __contains__(self, checksum):
00045         return checksum in self._mapping

Definition at line 52 of file backup_plugin.py.

00052 
00053     def __iter__(self):
00054         for checksum in self._mapping.keys():
00055             for chunkid in self._mapping[checksum]:
00056                 yield chunkid, checksum
00057 

def obnamlib.plugins.backup_plugin.ChunkidPool.add (   self,
  chunkid,
  checksum 
)

Definition at line 38 of file backup_plugin.py.

00038 
00039     def add(self, chunkid, checksum):
00040         if checksum not in self._mapping:
00041             self._mapping[checksum] = []
00042         self._mapping[checksum].append(chunkid)

Definition at line 49 of file backup_plugin.py.

00049 
00050     def clear(self):
00051         self._mapping = {}
        

Here is the caller graph for this function:

def obnamlib.plugins.backup_plugin.ChunkidPool.get (   self,
  checksum 
)

Definition at line 46 of file backup_plugin.py.

00046 
00047     def get(self, checksum):
00048         return self._mapping.get(checksum, [])
        

Member Data Documentation

Definition at line 50 of file backup_plugin.py.


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