Package Pyblio :: Package Stores :: Module filestore :: Class Database
[show private | hide private]
[frames | no frames]

Type Database

object --+    
         |    
  Database --+
             |
object --+   |
         |   |
 Publisher --+
             |
object --+   |
         |   |
 Queryable --+
             |
            Database


Method Summary
  __init__(self, schema, file, create)
  __delitem__(self, k)
  __getitem__(self, key)
Get a record by key.
  __setitem__(self, key, value)
  add(self, record, key)
Insert a new entry in the database.
  has_key(self, k)
  save(self)
    Inherited from Queryable
  query(self, query, permanent)
    Inherited from Database
  collate(self, rs, field)
Partition the result set in a list of sets for every value taken by the specified field
  validate(self, entry)
Check an entry for conformance against the Schema.
  xmlread(self, fd)
  xmlwrite(self, fd)
Output a database in XML format
    Inherited from Publisher
  emit(self, signal, *args)
Call this method to emit a signal.
  register(self, signal, callback, *args)
Clients interested in a given signal must register with this method.
  unregister(self, signal, callback)
Stop notifying events for the specified signal/callback pair.
    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)

Property Summary
    Inherited from Database
  entries

Class Variable Summary
    Inherited from Database
  entries = Pyblio.Store.Database.entries
  txo: a TxoGroup instance, containing all the taxonomy definitions in the database.

Method Details

__getitem__(self, key)
(Indexing operator)

Get a record by key.
Parameters:
key - the key of the requested record
           (type=a Key)
Overrides:
Pyblio.Store.Database.__getitem__ (inherited documentation)

add(self, record, key=None)

Insert a new entry in the database.

New entries MUST be added with this method, not via an update with a hand-made Key.

key is only useful for importing an existing database, by proposing a key choice.
Overrides:
Pyblio.Store.Database.add

Generated by Epydoc 2.1 on Wed Feb 15 23:19:37 2006 http://epydoc.sf.net