Package Bio :: Module Index :: Class _InMemoryIndex
[hide private]
[frames] | no frames]

Class _InMemoryIndex

source code

object --+    
         |    
      dict --+
             |
            _InMemoryIndex

This creates an in-memory index file.

    

Instance Methods [hide private]
new empty dictionary

__init__(self, indexname, truncate=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
None

update(self, dict)
Update D from dict/iterable E and F.
source code
 
__setitem__(self, key, value)
x[i]=y
source code
 
__delitem__(self, key)
del x[y]
source code
None

clear(self)
Remove all items from D.
source code
 
__del__(self) source code
 
_tostr(self, obj) source code
 
_toobj(self, str) source code

Inherited from dict: __cmp__, __contains__, __eq__, __ge__, __getattribute__, __getitem__, __gt__, __iter__, __le__, __len__, __lt__, __ne__, __new__, __repr__, __sizeof__, copy, fromkeys, get, has_key, items, iteritems, iterkeys, itervalues, keys, pop, popitem, setdefault, values

Inherited from object: __delattr__, __format__, __reduce__, __reduce_ex__, __setattr__, __str__, __subclasshook__

Class Variables [hide private]
  __version = 3
  __version_key = '__version'
  _InMemoryIndex__version = 3
  _InMemoryIndex__version_key = '__version'

Inherited from dict: __hash__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, indexname, truncate=None)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Returns:
new empty dictionary

Overrides: object.__init__
(inherited documentation)

update(self, dict)

source code 
Update D from dict/iterable E and F.
If E has a .keys() method, does:     for k in E: D[k] = E[k]
If E lacks .keys() method, does:     for (k, v) in E: D[k] = v
In either case, this is followed by: for k in F: D[k] = F[k]

Returns:
None

Overrides: dict.update
(inherited documentation)

__setitem__(self, key, value)
(Index assignment operator)

source code 
x[i]=y

Overrides: dict.__setitem__
(inherited documentation)

__delitem__(self, key)
(Index deletion operator)

source code 
del x[y]

Overrides: dict.__delitem__
(inherited documentation)

clear(self)

source code 
Remove all items from D.

Returns:
None

Overrides: dict.clear
(inherited documentation)