#include <sys/types.h>
#include <errno.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <db.h>
#include "../../basext.h"
Go to the source code of this file.
Data Structures | |
struct | _MyDb |
struct | _BdbObject |
Defines | |
#define | BDB_ERROR_INVALID_FILE_NAME 0x00080001 |
#define | BDB_ERROR_INVALID_DB_HANDLE 0x00080002 |
#define | BDB_ERROR_TRANSACTION_NOT_CLOSED 0x00080003 |
#define | BDB_ERROR_TRANSACTION_NOT_OPENED 0x00080004 |
#define | BDB_ERROR_KEY_NOT_FOUND 0x00080005 |
#define | BDB_INCOMPLETE 0x00080006 |
#define | BDB_KEYEMPTY 0x00080007 |
#define | BDB_KEYEXIST 0x00080008 |
#define | BDB_LOCK_DEADLOCK 0x00080009 |
#define | BDB_LOCK_NOTGRANTED 0x0008000A |
#define | BDB_NOTFOUND 0x0008000B |
#define | BDB_OLD_VERSION 0x0008000C |
#define | BDB_RUNRECOVERY 0x0008000D |
#define | BDB_DELETED 0x0008000E |
#define | BDB_NEEDSPLIT 0x0008000F |
#define | BDB_SWAPBYTES 0x00080010 |
#define | BDB_TXN_CKP 0x00080011 |
#define | X(A, B) |
#define | X(A, B) if( besCONFIG(B) && !strcmp(besCONFIG(B),"yes") )p->flags |= A; |
#define | X(A, B) if( s=besCONFIG(A) )p->dbenv->B = atol(s); |
Typedefs | |
typedef _MyDb | MyDb |
typedef _MyDb * | pMyDb |
typedef _BdbObject | BdbObject |
typedef _BdbObject * | pBdbObject |
Functions | |
static unsigned long | ConvertBdbErrors (int BdbError) |
besVERSION_NEGOTIATE | return (int) |
if (s=besCONFIG("bdb.limits.lg_max")) | |
if (if(=besCONFIG("bdb.dir.log")) p->dbenv->set_lg_dir(p->dbenv s=besCONFIG("bdb.dir.data")) | |
if (p==NULL) | |
p dbenv | close (p->dbenv, 0) |
besEND | besFUNCTION (sb_db_open) |
besCONVERT2ZCHAR (Argument, pszFileName) | |
besDEREFERENCE (Argument) | |
besCONVERT2LONG (Argument) | |
if (Argument) | |
dbpp | set_flags (dbpp, DB_DUP) |
besFREE (pszFileName) | |
if (ret) | |
if (if pTable==NULL) | |
besALLOC_RETURN_STRING (sizeof(pMyDb)) | |
memcpy (STRINGVALUE(besRETURNVALUE),&pTable, sizeof(DB *)) | |
besEND | besFUNCTION (sb_db_close) |
memcpy (&pTable, STRINGVALUE(Argument), sizeof(DB *)) | |
if (pTable->pCursor) pTable->pCursor->c_close(pTable->pCursor) = pTable->next | |
besFREE (pTable) | |
if (int ret) | |
memcpy (&pTable, STRINGVALUE(Argument), sizeof(pMyDb)) | |
memset (&key, 0, sizeof(DBT)) | |
if (VARIABLE Argument) | |
if (if(&&ret!=ENOMEM) return ConvertBdbErrors(ret) ret==DB_KEYEMPTY||ret==DB_NOTFOUND) | |
besEND | besFUNCTION (sb_db_trcommit) |
besEND | besFUNCTION (sb_db_trabort) |
Variables | |
return | |
besEND besSUB_FINISH pBdbObject | p |
pMyDb | pTable |
p = (pBdbObject)besMODULEPOINTER | |
return | |
Argument = besARGUMENT(2) | |
Argument = besARGUMENT(3) | |
ret | |
pTable = besALLOC(sizeof(MyDb)) | |
ret = dbpp->cursor(pTable->pdb,pTable->txnid,&(pTable->pCursor),0) | |
return | COMMAND_ERROR_SUCCESS |
dbpp = pTable->pdb | |
ret = dbpp->close(dbpp,0) | |
else p | pDbList = pTable->next |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
data | data = NULL |
data | ulen = 0 |
data | flags = DB_DBT_USERMEM |
ret = pTable->pCursor->c_get(pTable->pCursor,&key,&data,flags) | |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
data | data = NULL |
data | ulen = 0 |
data | flags = DB_DBT_USERMEM |
ret = pTable->pCursor->c_get(pTable->pCursor,&key,&data,DB_NEXT) | |
dbpp = pTable->pdb | |
key | data = NULL |
key | ulen = 0 |
key | flags = DB_DBT_USERMEM |
data | data = NULL |
data | ulen = 0 |
data | flags = DB_DBT_USERMEM |
ret = pTable->pCursor->c_get(pTable->pCursor,&key,&data,DB_CURRENT) | |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
data | data = NULL |
data | ulen = 0 |
data | flags = DB_DBT_USERMEM |
ret = pTable->pCursor->c_get(pTable->pCursor,&key,&data,DB_PREV) | |
dbpp = pTable->pdb | |
data | data = NULL |
data | ulen = 0 |
data | flags = DB_DBT_USERMEM |
ret = pTable->pCursor->c_get(pTable->pCursor,&key,&data,DB_LAST) | |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
dbpp = pTable->pdb | |
ret = pTable->pCursor->c_del(pTable->pCursor,0) | |
dbpp = pTable->pdb | |
Argument = besARGUMENT(2) | |
p | InTransaction = 1 |
return | COMMAND_ERROR_SUCCESS |
p | InTransaction = 0 |
return | COMMAND_ERROR_SUCCESS |
p | InTransaction = 0 |
return | COMMAND_ERROR_SUCCESS |
|
Definition at line 43 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 31 of file interface.c. Referenced by besFUNCTION(). |
|
Definition at line 30 of file interface.c. Referenced by besFUNCTION(). |
|
Definition at line 34 of file interface.c. |
|
Definition at line 32 of file interface.c. |
|
Definition at line 33 of file interface.c. |
|
Definition at line 35 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 36 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 37 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 38 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 39 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 44 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 40 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 41 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 42 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 45 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 46 of file interface.c. Referenced by ConvertBdbErrors(). |
|
Definition at line 153 of file interface.c. |
|
Definition at line 153 of file interface.c. |
|
Value: A = besCONFIG(B);\ if( A && !*A )A=NULL;\ if( A )iConfigLines++; Definition at line 153 of file interface.c. Referenced by pfEnv(), and pfFtpEnv(). |
|
|
|
|
|
|
|
|
|
Referenced by besFUNCTION(), if(), and switch(). |
|
Referenced by basext_GetArgsF(), besFUNCTION(), if(), and switch(). |
|
Referenced by besFUNCTION(), CHECK_OPTION(), and if(). |
|
Referenced by basext_GetArgsF(), besFUNCTION(), CHECK_OPTION(), if(), and return(). |
|
|
|
Referenced by __RemoveImage(), basext_GetArgsF(), besFUNCTION(), buffercollect(), CHECK_OPTION(), delete_Wrapper(), F_LibraryLoaded(), if(), release_list(), switch(), and zlibfree_interface(). |
|
Definition at line 939 of file interface.c. |
|
Definition at line 917 of file interface.c. |
|
Definition at line 345 of file interface.c. References BDB_ERROR_INVALID_DB_HANDLE. |
|
Definition at line 226 of file interface.c. References BDB_ERROR_INVALID_FILE_NAME, and besRETURNVALUE. |
|
|
|
Definition at line 69 of file interface.c. References BDB_DELETED, BDB_INCOMPLETE, BDB_KEYEMPTY, BDB_KEYEXIST, BDB_LOCK_DEADLOCK, BDB_LOCK_NOTGRANTED, BDB_NEEDSPLIT, BDB_NOTFOUND, BDB_OLD_VERSION, BDB_RUNRECOVERY, BDB_SWAPBYTES, BDB_TXN_CKP, DB_DELETED, DB_INCOMPLETE, DB_KEYEMPTY, DB_KEYEXIST, DB_LOCK_DEADLOCK, DB_LOCK_NOTGRANTED, DB_NEEDSPLIT, DB_NOTFOUND, DB_OLD_VERSION, DB_RUNRECOVERY, DB_SWAPBYTES, and DB_TXN_CKP. Referenced by if(). |
|
Definition at line 510 of file interface.c. |
|
Definition at line 446 of file interface.c. |
|
Definition at line 380 of file interface.c. |
|
|
|
Definition at line 315 of file interface.c. References ConvertBdbErrors(), p, pTable, ret, and _MyDb::txnid. |
|
Definition at line 310 of file interface.c. References besRETURNVALUE, ConvertBdbErrors(), and ret. |
|
Definition at line 254 of file interface.c. References DB_BTREE, DB_HASH, DB_QUEUE, DB_RECNO, DB_UNKNOWN, and type. |
|
Definition at line 195 of file interface.c. References _MyDb::next, NULL, _MyDb::pCursor, _MyDb::pdb, pTable, and _MyDb::txnid. |
|
Definition at line 173 of file interface.c. |
|
Definition at line 157 of file interface.c. References DB_LOCK_DEFAULT, DB_LOCK_OLDEST, DB_LOCK_RANDOM, and DB_LOCK_YOUNGEST. |
|
|
|
|
|
|
|
|
Definition at line 91 of file interface.c. |
|
|
|
Definition at line 837 of file interface.c. |
|
Definition at line 760 of file interface.c. |
|
Definition at line 655 of file interface.c. |
|
Definition at line 548 of file interface.c. |
|
Definition at line 489 of file interface.c. |
|
Definition at line 419 of file interface.c. |
|
Definition at line 268 of file interface.c. |
|
Definition at line 251 of file interface.c. |
|
Definition at line 958 of file interface.c. |
|
Definition at line 936 of file interface.c. |
|
Definition at line 914 of file interface.c. |
|
|
Definition at line 712 of file interface.c. |
|
Definition at line 667 of file interface.c. |
|
Definition at line 609 of file interface.c. |
|
Definition at line 604 of file interface.c. |
|
Definition at line 560 of file interface.c. |
|
Definition at line 504 of file interface.c. |
|
Definition at line 831 of file interface.c. |
|
Definition at line 802 of file interface.c. |
|
Definition at line 756 of file interface.c. |
|
Definition at line 707 of file interface.c. |
|
Definition at line 651 of file interface.c. |
|
Definition at line 601 of file interface.c. |
|
Definition at line 544 of file interface.c. |
|
Definition at line 485 of file interface.c. |
|
Definition at line 414 of file interface.c. |
|
Definition at line 365 of file interface.c. |
|
Definition at line 714 of file interface.c. |
|
Definition at line 669 of file interface.c. |
|
Definition at line 611 of file interface.c. |
|
Definition at line 606 of file interface.c. |
|
Definition at line 562 of file interface.c. |
|
Definition at line 506 of file interface.c. Referenced by printDouble(), and printInt(). |
|
Definition at line 957 of file interface.c. |
|
Definition at line 935 of file interface.c. |
|
Definition at line 913 of file interface.c. |
|
Definition at line 193 of file interface.c. |
|
Definition at line 190 of file interface.c. |
|
Definition at line 373 of file interface.c. |
|
Definition at line 314 of file interface.c. |
|
Definition at line 191 of file interface.c. Referenced by if(). |
|
Definition at line 804 of file interface.c. |
|
Definition at line 717 of file interface.c. |
|
Definition at line 672 of file interface.c. |
|
Definition at line 614 of file interface.c. |
|
Definition at line 565 of file interface.c. |
|
Definition at line 509 of file interface.c. |
|
Definition at line 368 of file interface.c. |
|
Definition at line 331 of file interface.c. |
|
Initial value: dbpp->open(dbpp, NULL, pszFileName, NULL, /* sub databases are not supported yet */ type, flags, mode) Definition at line 300 of file interface.c. Referenced by build_IsFileBinaryFormat(), dupl(), end(), if(), and pathdialog(). |
|
Definition at line 211 of file interface.c. |
|
Definition at line 186 of file interface.c. Referenced by brushupinline(). |
|
Definition at line 713 of file interface.c. |
|
Definition at line 668 of file interface.c. |
|
Definition at line 610 of file interface.c. |
|
Definition at line 605 of file interface.c. |
|
Definition at line 561 of file interface.c. |
|
Definition at line 505 of file interface.c. |