Metadata-Version: 1.0
Name: odbm
Version: 0.3
Summary: Object wrapper for dbms
Home-page: http://bitbucket.org/imbolc/odbm/
Author: Imbolc
Author-email: imbolc@imbolc.name
License: BSD
Description: odbm
        ====
        
        Installation
        ------------
        
            $  pip install odbm
        
        Usage
        -----
            
            >>> class Test(Model):
            ...     day     = DateProperty(primary_key=True)
            ...     foo     = Property(default=[1, 2])
            ...     ustr    = UnicodeProperty(key='u')
            ...     cstr    = CompressedStringProperty()
            ...     cuni    = CompressedUnicodeProperty() 
            ...     cdump   = CompressedProperty(default={}) 
            ...     created = DateTimeProperty(key='c')
            ...
            ...     __db_type__ = 'dict'
            
            >>> Test(
            ...     day     = date(2000, 01, 02),
            ...     foo     = [1, u'ы', {'a': 'b'}],
            ...     ustr    = u'ыыы',
            ...     cstr    = 'A' * 1000,
            ...     cuni    = u'Ы' * 1000,
            ...     cdump   = range(10),
            ...     created = datetime.now(),
            ... ).save()
            >>> Test(day=date(1999, 02, 02)).save()
            
            >>> Test.get(date(1999, 02, 02)).foo
            [1, 2]
            
            >>> Test.count()
            2
            >>> Test.count(lambda x: x.ustr == u'ыыы')
            1
            
            >>> [t.day.year for t in Test.find(
            ...     filter  = lambda x: 3 not in x.foo,
            ...     order   = lambda x: x.day)]
            [1999, 2000]
            
            >>> Test.find_one().delete()
            >>> Test.count()
        
Keywords: dbm
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Topic :: Software Development :: Libraries :: Python Modules
