Package conduit :: Module Database
[hide private]

Module Database

source code


Sqlite DB Abstraction layer and threadsafe wrapping around it.
Copyright (C) John Stowers 2007 <john.stowers@gmail.com>

GenericDB:
SQL based on http://vwdude.com/dropbox/pystore/
Copyright (C) Christian Hergert 2007 <christian.hergert@gmail.com>

ThreadSafeGenericDB:
Wrapper based on http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/526618
Copyright (C) Louis RIVIERE 2007

You may redistribute it and/or modify it under the terms of the
GNU General Public License, as published by the Free Software
Foundation; either version 2 of the License, or (at your option)
any later version.
 
main.c is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU General Public License for more details.
 
You should have received a copy of the GNU General Public License
along with main.c.  If not, write to:
 The Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor
 Boston, MA  02110-1301, USA.



Classes [hide private]
  GenericDB
GenericDB abstraction layer.
  ThreadSafeGenericDB
Threadsafe wrapper around GenericDB Abstraction layer.
Functions [hide private]
 
lru_cache(maxsize)
Decorator applying a least-recently-used cache with the given maximum size.
source code
Variables [hide private]
  log = logging.getLogger("Database")
Function Details [hide private]

lru_cache(maxsize)

source code 

Decorator applying a least-recently-used cache with the given maximum size.

Arguments to the cached function must be hashable. Cache performance statistics stored in f.hits and f.misses.