static PyObject *BsddbError;
static PyObject *
-newdbhashobject(file, flags, mode,
- bsize, ffactor, nelem, cachesize, hash, lorder)
- char *file;
- int flags;
- int mode;
- int bsize;
- int ffactor;
- int nelem;
- int cachesize;
- int hash; /* XXX ignored */
- int lorder;
+newdbhashobject(char *file, int flags, int mode,
+ int bsize, int ffactor, int nelem, int cachesize, int hash, int lorder)
{
bsddbobject *dp;
HASHINFO info;
}
static PyObject *
-newdbbtobject(file, flags, mode,
- btflags, cachesize, maxkeypage, minkeypage, psize, lorder)
- char *file;
- int flags;
- int mode;
- int btflags;
- int cachesize;
- int maxkeypage;
- int minkeypage;
- int psize;
- int lorder;
+newdbbtobject(char *file, int flags, int mode,
+ int btflags, int cachesize, int maxkeypage, int minkeypage, int psize, int lorder)
{
bsddbobject *dp;
BTREEINFO info;
}
static PyObject *
-newdbrnobject(file, flags, mode,
- rnflags, cachesize, psize, lorder, reclen, bval, bfname)
- char *file;
- int flags;
- int mode;
- int rnflags;
- int cachesize;
- int psize;
- int lorder;
- size_t reclen;
- u_char bval;
- char *bfname;
+newdbrnobject(char *file, int flags, int mode,
+ int rnflags, int cachesize, int psize, int lorder, size_t reclen, u_char bval, char *bfname)
{
bsddbobject *dp;
RECNOINFO info;
}
static void
-bsddb_dealloc(dp)
- bsddbobject *dp;
+bsddb_dealloc(bsddbobject *dp)
{
#ifdef WITH_THREAD
if (dp->di_lock) {
#endif
static int
-bsddb_length(dp)
- bsddbobject *dp;
+bsddb_length(bsddbobject *dp)
{
if (dp->di_bsddb == NULL) {
PyErr_SetString(BsddbError, "BSDDB object has already been closed");
}
static PyObject *
-bsddb_subscript(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_subscript(bsddbobject *dp, PyObject *key)
{
int status;
DBT krec, drec;
}
static int
-bsddb_ass_sub(dp, key, value)
- bsddbobject *dp;
- PyObject *key, *value;
+bsddb_ass_sub(bsddbobject *dp, PyObject *key, PyObject *value)
{
int status;
DBT krec, drec;
};
static PyObject *
-bsddb_close(dp, args)
- bsddbobject *dp;
- PyObject *args;
+bsddb_close(bsddbobject *dp, PyObject *args)
{
if (!PyArg_NoArgs(args))
return NULL;
}
static PyObject *
-bsddb_keys(dp, args)
- bsddbobject *dp;
- PyObject *args;
+bsddb_keys(bsddbobject *dp, PyObject *args)
{
PyObject *list, *item;
DBT krec, drec;
}
static PyObject *
-bsddb_has_key(dp, args)
- bsddbobject *dp;
- PyObject *args;
+bsddb_has_key(bsddbobject *dp, PyObject *args)
{
DBT krec, drec;
int status;
}
static PyObject *
-bsddb_set_location(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_set_location(bsddbobject *dp, PyObject *key)
{
int status;
DBT krec, drec;
}
static PyObject *
-bsddb_seq(dp, args, sequence_request)
- bsddbobject *dp;
- PyObject *args;
- int sequence_request;
+bsddb_seq(bsddbobject *dp, PyObject *args, int sequence_request)
{
int status;
DBT krec, drec;
}
static PyObject *
-bsddb_next(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_next(bsddbobject *dp, PyObject *key)
{
return bsddb_seq(dp, key, R_NEXT);
}
static PyObject *
-bsddb_previous(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_previous(bsddbobject *dp, PyObject *key)
{
return bsddb_seq(dp, key, R_PREV);
}
static PyObject *
-bsddb_first(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_first(bsddbobject *dp, PyObject *key)
{
return bsddb_seq(dp, key, R_FIRST);
}
static PyObject *
-bsddb_last(dp, key)
- bsddbobject *dp;
- PyObject *key;
+bsddb_last(bsddbobject *dp, PyObject *key)
{
return bsddb_seq(dp, key, R_LAST);
}
static PyObject *
-bsddb_sync(dp, args)
- bsddbobject *dp;
- PyObject *args;
+bsddb_sync(bsddbobject *dp, PyObject *args)
{
int status;
};
static PyObject *
-bsddb_getattr(dp, name)
- PyObject *dp;
- char *name;
+bsddb_getattr(PyObject *dp, char *name)
{
return Py_FindMethod(bsddb_methods, dp, name);
}
};
static PyObject *
-bsdhashopen(self, args)
- PyObject *self;
- PyObject *args;
+bsdhashopen(PyObject *self, PyObject *args)
{
char *file;
char *flag = NULL;
}
static PyObject *
-bsdbtopen(self, args)
- PyObject *self;
- PyObject *args;
+bsdbtopen(PyObject *self, PyObject *args)
{
char *file;
char *flag = NULL;
}
static PyObject *
-bsdrnopen(self, args)
- PyObject *self;
- PyObject *args;
+bsdrnopen(PyObject *self, PyObject *args)
{
char *file;
char *flag = NULL;
static PyObject *DbmError;
static PyObject *
-newdbmobject(file, flags, mode)
- char *file;
-int flags;
-int mode;
+newdbmobject(char *file, int flags, int mode)
{
dbmobject *dp;
/* Methods */
static void
-dbm_dealloc(dp)
- register dbmobject *dp;
+dbm_dealloc(register dbmobject *dp)
{
if ( dp->di_dbm )
dbm_close(dp->di_dbm);
}
static int
-dbm_length(dp)
- dbmobject *dp;
+dbm_length(dbmobject *dp)
{
if (dp->di_dbm == NULL) {
PyErr_SetString(DbmError, "DBM object has already been closed");
}
static PyObject *
-dbm_subscript(dp, key)
- dbmobject *dp;
-register PyObject *key;
+dbm_subscript(dbmobject *dp, register PyObject *key)
{
datum drec, krec;
}
static int
-dbm_ass_sub(dp, v, w)
- dbmobject *dp;
-PyObject *v, *w;
+dbm_ass_sub(dbmobject *dp, PyObject *v, PyObject *w)
{
datum krec, drec;
};
static PyObject *
-dbm__close(dp, args)
- register dbmobject *dp;
-PyObject *args;
+dbm__close(register dbmobject *dp, PyObject *args)
{
if ( !PyArg_NoArgs(args) )
return NULL;
}
static PyObject *
-dbm_keys(dp, args)
- register dbmobject *dp;
-PyObject *args;
+dbm_keys(register dbmobject *dp, PyObject *args)
{
register PyObject *v, *item;
datum key;
}
static PyObject *
-dbm_has_key(dp, args)
- register dbmobject *dp;
-PyObject *args;
+dbm_has_key(register dbmobject *dp, PyObject *args)
{
datum key, val;
};
static PyObject *
-dbm_getattr(dp, name)
- dbmobject *dp;
-char *name;
+dbm_getattr(dbmobject *dp, char *name)
{
return Py_FindMethod(dbm_methods, (PyObject *)dp, name);
}
/* ----------------------------------------------------------------- */
static PyObject *
-dbmopen(self, args)
- PyObject *self;
-PyObject *args;
+dbmopen(PyObject *self, PyObject *args)
{
char *name;
char *flags = "r";