Journaling dbm
Allowed backends
‘memory’ (mostly for tests)
‘tc’ (tokyo cabinet)
Usage
>>> from jdbm import jdbm
>>> db = jdbm('tc', filename='var/readme-test.tc',
... journal_filename='var/readme-test.journal.tc')
Standard operations:
>>> db.put('a', 'foo')
>>> db.put('b', 'bar')
>>> db.get('a')
'foo'
>>> set(k for k in db)
set(['a', 'b'])
>>> db.exists('a')
True
>>> db.delete('a')
>>> db.length()
1
Restore db from journal:
>>> db.clear(journaling=False) >>> db.length() 0 >>> db.restore_from_journal() >>> db.length() 1
Release files for jdbm 1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| jdbm-1.0.tar.gz | 2.8 kB | Details |
Release files / jdbm-1.0.tar.gz
| Download URL | jdbm-1.0.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f833f6c00675bc6bdaa8d89e88bb117acdea6a2017e354122009648fc3295784
|
|
BLAKE2b-256 checksum How to use checksums |
696923905abd2ba6a530534bf1f4190f6e73acdfe67953ae216f51236e743e77
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |