Package twisted :: Package popsicle :: Module picklesicle :: Class Picklesicle
[frames | no frames]

Class Picklesicle

     Repository --+    
                  |    
DirectoryRepository --+
                      |
                     Picklesicle


I am a Repository that uses a directory full of Pickles to save everything. This is the most naive implementation possible of a popsicle backend, and useful for reference implementors.
Method Summary
  __init__(self, dirname, persistentClasses)
  loadOID(self, oid)
Implement me to return a Deferred if you want to implement asynchronous loading.
  persistentID(self, obj)
  persistentLoad(self, pid)
  saveOID(self, oid, obj)
Return a Deferred which will fire True when the object is saved.
    Inherited from DirectoryRepository
  generateOID(self, obj)
Generate an OID synchronously.
    Inherited from Repository
  __getstate__(self)
  __setstate__(self, dct)
  _cbLoadedOID(self, result, oid, pref)
  cache(self, oid, obj, finished)
Weakly cache an object for the given OID.
  cleaned(self)
The freezer finished cleaning, and some of my objects were cleaned.
  createOID(self, oid, klass)
Create an instance with an oid and cache it.
  getOID(self, obj)
  load(self, oid)
Load an object from cache or by OID.
  loadNow(self, oid)
External API for synchronously loading stuff.
  loadOIDNow(self, oid)
Implement me if you want to implement synchronous loading.
  loadRef(self, pRef)
Synonymous with ref.__call__().
  save(self, obj)
Save an object...

Class Variable Summary
    Inherited from Repository
int _lastOID = 0                                                                     

Method Details

loadOID(self, oid)

Implement me to return a Deferred if you want to implement asynchronous loading.
Overrides:
twisted.popsicle.repos.Repository.loadOID (inherited documentation)

saveOID(self, oid, obj)

Return a Deferred which will fire True when the object is saved.
Overrides:
twisted.popsicle.repos.Repository.saveOID (inherited documentation)

Generated by Epydoc 2.0 on Sat Sep 13 04:20:47 2003 http://epydoc.sf.net