Package amplee :: Package indexer :: Class ShelveContainer
[show private | hide private]
[frames | no frames]

Type ShelveContainer

object --+
         |
        ShelveContainer


Method Summary
  __init__(self, abs_path, protocol)
Simple container around the built-in shelve module.
  __contains__(self, key)
  __delitem__(self, key)
  __getitem__(self, key)
  __iter__(self)
  __setitem__(self, key, value)
  iterkeys(self)
  shutdown(self)
Closes the shelve container when not needed anymore.
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __repr__(x)
x.__repr__() <==> repr(x)
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)

Method Details

__init__(self, abs_path, protocol=2)
(Constructor)

Simple container around the built-in shelve module. This provides a simple and more-or-less efficient persistence system.

The ``abs_path`` is the absolute path of the shelve to open (and create if it does not exist).

The ``protocol`` is the protocol value used by the open() function of the shelve module.

If you plan to create your own container, they must implement the start and shutdown methods as-is.
Overrides:
__builtin__.object.__init__

shutdown(self)

Closes the shelve container when not needed anymore.

Generated by Epydoc 2.1 on Thu Jul 19 15:32:16 2007 http://epydoc.sf.net