亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? tcbdb.h

?? Tokyo Cabinet的Tokyo Cabinet 是一個DBM的實現(xiàn)。這里的數(shù)據(jù)庫由一系列key-value對的記錄構(gòu)成。key和value都可以是任意長度的字節(jié)序列,既可以是二進制也可以是字符
?? H
?? 第 1 頁 / 共 4 頁
字號:
/************************************************************************************************* * The B+ tree database API of Tokyo Cabinet *                                                      Copyright (C) 2006-2009 Mikio Hirabayashi * This file is part of Tokyo Cabinet. * Tokyo Cabinet is free software; you can redistribute it and/or modify it under the terms of * the GNU Lesser General Public License as published by the Free Software Foundation; either * version 2.1 of the License or any later version.  Tokyo Cabinet 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 Lesser General Public * License for more details. * You should have received a copy of the GNU Lesser General Public License along with Tokyo * Cabinet; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, * Boston, MA 02111-1307 USA. *************************************************************************************************/#ifndef _TCBDB_H                         /* duplication check */#define _TCBDB_H#if defined(__cplusplus)#define __TCBDB_CLINKAGEBEGIN extern "C" {#define __TCBDB_CLINKAGEEND }#else#define __TCBDB_CLINKAGEBEGIN#define __TCBDB_CLINKAGEEND#endif__TCBDB_CLINKAGEBEGIN#include <stdlib.h>#include <stdbool.h>#include <stdint.h>#include <time.h>#include <limits.h>#include <math.h>#include <tcutil.h>#include <tchdb.h>/************************************************************************************************* * API *************************************************************************************************/typedef struct {                         /* type of structure for a B+ tree database */  void *mmtx;                            /* mutex for method */  void *cmtx;                            /* mutex for cache */  TCHDB *hdb;                            /* internal database object */  char *opaque;                          /* opaque buffer */  bool open;                             /* whether the internal database is opened */  bool wmode;                            /* whether to be writable */  uint32_t lmemb;                        /* number of members in each leaf */  uint32_t nmemb;                        /* number of members in each node */  uint8_t opts;                          /* options */  uint64_t root;                         /* ID number of the root page */  uint64_t first;                        /* ID number of the first leaf */  uint64_t last;                         /* ID number of the last leaf */  uint64_t lnum;                         /* number of leaves */  uint64_t nnum;                         /* number of nodes */  uint64_t rnum;                         /* number of records */  TCMAP *leafc;                          /* cache for leaves */  TCMAP *nodec;                          /* cache for nodes */  TCCMP cmp;                             /* pointer to the comparison function */  void *cmpop;                           /* opaque object for the comparison function */  uint32_t lcnum;                        /* maximum number of cached leaves */  uint32_t ncnum;                        /* maximum number of cached nodes */  uint32_t lsmax;                        /* maximum size of each leaf */  uint32_t lschk;                        /* counter for leaf size checking */  uint64_t capnum;                       /* capacity number of records */  uint64_t *hist;                        /* history array of visited nodes */  int hnum;                              /* number of element of the history array */  uint64_t hleaf;                        /* ID number of the leaf referred by the history */  uint64_t lleaf;                        /* ID number of the last visited leaf */  bool tran;                             /* whether in the transaction */  char *rbopaque;                        /* opaque for rollback */  uint64_t clock;                        /* logical clock */  int64_t cnt_saveleaf;                  /* tesing counter for leaf save times */  int64_t cnt_loadleaf;                  /* tesing counter for leaf load times */  int64_t cnt_killleaf;                  /* tesing counter for leaf kill times */  int64_t cnt_adjleafc;                  /* tesing counter for node cache adjust times */  int64_t cnt_savenode;                  /* tesing counter for node save times */  int64_t cnt_loadnode;                  /* tesing counter for node load times */  int64_t cnt_adjnodec;                  /* tesing counter for node cache adjust times */} TCBDB;enum {                                   /* enumeration for additional flags */  BDBFOPEN = HDBFOPEN,                   /* whether opened */  BDBFFATAL = HDBFFATAL                  /* whetehr with fatal error */};enum {                                   /* enumeration for tuning options */  BDBTLARGE = 1 << 0,                    /* use 64-bit bucket array */  BDBTDEFLATE = 1 << 1,                  /* compress each page with Deflate */  BDBTBZIP = 1 << 2,                     /* compress each record with BZIP2 */  BDBTTCBS = 1 << 3,                     /* compress each page with TCBS */  BDBTEXCODEC = 1 << 4                   /* compress each record with outer functions */};enum {                                   /* enumeration for open modes */  BDBOREADER = 1 << 0,                   /* open as a reader */  BDBOWRITER = 1 << 1,                   /* open as a writer */  BDBOCREAT = 1 << 2,                    /* writer creating */  BDBOTRUNC = 1 << 3,                    /* writer truncating */  BDBONOLCK = 1 << 4,                    /* open without locking */  BDBOLCKNB = 1 << 5,                    /* lock without blocking */  BDBOTSYNC = 1 << 6                     /* synchronize every transaction */};typedef struct {                         /* type of structure for a B+ tree cursor */  TCBDB *bdb;                            /* database object */  uint64_t clock;                        /* logical clock */  uint64_t id;                           /* ID number of the leaf */  int32_t kidx;                          /* number of the key */  int32_t vidx;                          /* number of the value */} BDBCUR;enum {                                   /* enumeration for cursor put mode */  BDBCPCURRENT,                          /* current */  BDBCPBEFORE,                           /* before */  BDBCPAFTER                             /* after */};/* Get the message string corresponding to an error code.   `ecode' specifies the error code.   The return value is the message string of the error code. */const char *tcbdberrmsg(int ecode);/* Create a B+ tree database object.   The return value is the new B+ tree database object. */TCBDB *tcbdbnew(void);/* Delete a B+ tree database object.   `bdb' specifies the B+ tree database object.   If the database is not closed, it is closed implicitly.  Note that the deleted object and its   derivatives can not be used anymore. */void tcbdbdel(TCBDB *bdb);/* Get the last happened error code of a B+ tree database object.   `bdb' specifies the B+ tree database object.   The return value is the last happened error code.   The following error codes are defined: `TCESUCCESS' for success, `TCETHREAD' for threading   error, `TCEINVALID' for invalid operation, `TCENOFILE' for file not found, `TCENOPERM' for no   permission, `TCEMETA' for invalid meta data, `TCERHEAD' for invalid record header, `TCEOPEN'   for open error, `TCECLOSE' for close error, `TCETRUNC' for trunc error, `TCESYNC' for sync   error, `TCESTAT' for stat error, `TCESEEK' for seek error, `TCEREAD' for read error,   `TCEWRITE' for write error, `TCEMMAP' for mmap error, `TCELOCK' for lock error, `TCEUNLINK'   for unlink error, `TCERENAME' for rename error, `TCEMKDIR' for mkdir error, `TCERMDIR' for   rmdir error, `TCEKEEP' for existing record, `TCENOREC' for no record found, and `TCEMISC' for   miscellaneous error. */int tcbdbecode(TCBDB *bdb);/* Set mutual exclusion control of a B+ tree database object for threading.   `bdb' specifies the B+ tree database object which is not opened.   If successful, the return value is true, else, it is false.   Note that the mutual exclusion control is needed if the object is shared by plural threads and   this function should should be called before the database is opened. */bool tcbdbsetmutex(TCBDB *bdb);/* Set the custom comparison function of a B+ tree database object.   `bdb' specifies the B+ tree database object which is not opened.   `cmp' specifies the pointer to the custom comparison function.  It receives five parameters.   The first parameter is the pointer to the region of one key.  The second parameter is the size   of the region of one key.  The third parameter is the pointer to the region of the other key.   The fourth parameter is the size of the region of the other key.  The fifth parameter is the   pointer to the optional opaque object.  It returns positive if the former is big, negative if   the latter is big, 0 if both are equivalent.   `cmpop' specifies an arbitrary pointer to be given as a parameter of the comparison function.   If it is not needed, `NULL' can be specified.   If successful, the return value is true, else, it is false.   The default comparison function compares keys of two records by lexical order.  The functions   `tctccmplexical' (dafault), `tctccmpdecimal', `tctccmpint32', and `tctccmpint64' are built-in.   Note that the comparison function should be set before the database is opened.  Moreover,   user-defined comparison functions should be set every time the database is being opened. */bool tcbdbsetcmpfunc(TCBDB *bdb, TCCMP cmp, void *cmpop);/* Set the tuning parameters of a B+ tree database object.   `bdb' specifies the B+ tree database object which is not opened.   `lmemb' specifies the number of members in each leaf page.  If it is not more than 0, the   default value is specified.  The default value is 128.   `nmemb' specifies the number of members in each non-leaf page.  If it is not more than 0, the   default value is specified.  The default value is 256.   `bnum' specifies the number of elements of the bucket array.  If it is not more than 0, the   default value is specified.  The default value is 32749.  Suggested size of the bucket array   is about from 1 to 4 times of the number of all pages to be stored.   `apow' specifies the size of record alignment by power of 2.  If it is negative, the default   value is specified.  The default value is 8 standing for 2^8=256.   `fpow' specifies the maximum number of elements of the free block pool by power of 2.  If it   is negative, the default value is specified.  The default value is 10 standing for 2^10=1024.   `opts' specifies options by bitwise-or: `BDBTLARGE' specifies that the size of the database   can be larger than 2GB by using 64-bit bucket array, `BDBTDEFLATE' specifies that each page   is compressed with Deflate encoding, `BDBTBZIP' specifies that each page is compressed with   BZIP2 encoding, `BDBTTCBS' specifies that each page is compressed with TCBS encoding.   If successful, the return value is true, else, it is false.   Note that the tuning parameters should be set before the database is opened. */bool tcbdbtune(TCBDB *bdb, int32_t lmemb, int32_t nmemb,               int64_t bnum, int8_t apow, int8_t fpow, uint8_t opts);/* Set the caching parameters of a B+ tree database object.   `bdb' specifies the B+ tree database object which is not opened.   `lcnum' specifies the maximum number of leaf nodes to be cached.  If it is not more than 0,   the default value is specified.  The default value is 1024.   `ncnum' specifies the maximum number of non-leaf nodes to be cached.  If it is not more than 0,   the default value is specified.  The default value is 512.   If successful, the return value is true, else, it is false.   Note that the caching parameters should be set before the database is opened. */bool tcbdbsetcache(TCBDB *bdb, int32_t lcnum, int32_t ncnum);/* Set the size of the extra mapped memory of a B+ tree database object.   `bdb' specifies the B+ tree database object which is not opened.   `xmsiz' specifies the size of the extra mapped memory.  If it is not more than 0, the extra   mapped memory is disabled.  It is disabled by default.   If successful, the return value is true, else, it is false.   Note that the mapping parameters should be set before the database is opened. */bool tcbdbsetxmsiz(TCBDB *bdb, int64_t xmsiz);/* Open a database file and connect a B+ tree database object.   `bdb' specifies the B+ tree database object which is not opened.   `path' specifies the path of the database file.   `omode' specifies the connection mode: `BDBOWRITER' as a writer, `BDBOREADER' as a reader.   If the mode is `BDBOWRITER', the following may be added by bitwise-or: `BDBOCREAT', which   means it creates a new database if not exist, `BDBOTRUNC', which means it creates a new   database regardless if one exists, `BDBOTSYNC', which means every transaction synchronizes   updated contents with the device.  Both of `BDBOREADER' and `BDBOWRITER' can be added to by   bitwise-or: `BDBONOLCK', which means it opens the database file without file locking, or   `BDBOLCKNB', which means locking is performed without blocking.   If successful, the return value is true, else, it is false. */bool tcbdbopen(TCBDB *bdb, const char *path, int omode);/* Close a B+ tree database object.   `bdb' specifies the B+ tree database object.   If successful, the return value is true, else, it is false.   Update of a database is assured to be written when the database is closed.  If a writer opens   a database but does not close it appropriately, the database will be broken. */bool tcbdbclose(TCBDB *bdb);/* Store a record into a B+ tree database object.   `bdb' specifies the B+ tree database object connected as a writer.   `kbuf' specifies the pointer to the region of the key.   `ksiz' specifies the size of the region of the key.   `vbuf' specifies the pointer to the region of the value.   `vsiz' specifies the size of the region of the value.   If successful, the return value is true, else, it is false.   If a record with the same key exists in the database, it is overwritten. */bool tcbdbput(TCBDB *bdb, const void *kbuf, int ksiz, const void *vbuf, int vsiz);/* Store a string record into a B+ tree database object.   `bdb' specifies the B+ tree database object connected as a writer.   `kstr' specifies the string of the key.   `vstr' specifies the string of the value.   If successful, the return value is true, else, it is false.   If a record with the same key exists in the database, it is overwritten. */bool tcbdbput2(TCBDB *bdb, const char *kstr, const char *vstr);/* Store a new record into a B+ tree database object.   `bdb' specifies the B+ tree database object connected as a writer.   `kbuf' specifies the pointer to the region of the key.

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美国产一区二区在线观看| 精品国产第一区二区三区观看体验 | 亚洲chinese男男1069| 亚洲男人的天堂网| 一二三区精品福利视频| 亚洲成人av福利| 蜜桃久久久久久久| 国产麻豆精品久久一二三| 国产xxx精品视频大全| 成人午夜激情片| 91行情网站电视在线观看高清版| 欧美图区在线视频| 91精品国产乱码久久蜜臀| 精品国产一区二区三区不卡| 国产亚洲一区二区三区四区| 中文欧美字幕免费| 亚洲电影第三页| 国产麻豆成人精品| 色悠悠久久综合| 91精品欧美一区二区三区综合在 | 成人免费毛片嘿嘿连载视频| 99久久免费精品| 欧美日本精品一区二区三区| 欧美本精品男人aⅴ天堂| 国产精品久久一级| 亚欧色一区w666天堂| 国产一区二区三区观看| 色综合中文字幕国产 | 国产精品久99| 日韩电影免费一区| 国产xxx精品视频大全| 欧美综合色免费| 国产午夜精品理论片a级大结局 | 国产成人精品影院| 欧美日韩精品一区二区三区| 久久精品夜夜夜夜久久| 丝袜美腿一区二区三区| 99久久精品国产网站| 日韩欧美电影一二三| 亚洲欧美日韩在线不卡| 国产美女娇喘av呻吟久久| 欧美午夜精品理论片a级按摩| 久久午夜电影网| 午夜久久久久久久久久一区二区| 成人三级在线视频| 久久综合资源网| 日韩精品国产精品| 色综合一区二区三区| 2022国产精品视频| 日韩一区精品视频| 日本精品裸体写真集在线观看| 久久免费电影网| 免费人成精品欧美精品| 在线成人免费观看| 亚洲一区二区三区四区不卡| 国产精品自拍在线| 欧美一区二区国产| 日本午夜一本久久久综合| 在线观看亚洲精品视频| 国产精品久久久久毛片软件| 国产精品91一区二区| 2欧美一区二区三区在线观看视频| 日本欧美在线观看| 欧美日韩视频在线第一区| 亚洲老司机在线| 色偷偷88欧美精品久久久| 亚洲日本中文字幕区| 97久久人人超碰| 亚洲三级在线看| 91成人国产精品| 性做久久久久久久久| 7777精品伊人久久久大香线蕉最新版| 洋洋成人永久网站入口| 欧美在线一区二区| 香蕉av福利精品导航| 欧美日韩视频在线一区二区| 亚洲香肠在线观看| 欧美日韩你懂的| 男女男精品网站| 精品国产99国产精品| 国内精品免费**视频| 久久天天做天天爱综合色| 国产精品一区二区果冻传媒| 国产亚洲精品aa午夜观看| av中文字幕一区| 亚洲综合区在线| 欧美第一区第二区| 国产高清一区日本| 亚洲免费毛片网站| 日本精品视频一区二区| 日本伊人色综合网| 久久精品男人的天堂| 91麻豆精东视频| 亚洲123区在线观看| 337p粉嫩大胆噜噜噜噜噜91av | 亚洲精品你懂的| 91麻豆精品国产91久久久| 精品伊人久久久久7777人| 欧美激情在线看| 欧美日韩1234| 国产成人三级在线观看| 亚洲一线二线三线视频| 久久综合资源网| 欧美视频日韩视频在线观看| 狠狠色综合播放一区二区| 亚洲免费毛片网站| 26uuu久久天堂性欧美| 色视频一区二区| 国产精品一卡二卡在线观看| 亚洲与欧洲av电影| 久久久久久久久蜜桃| 欧美日韩一区二区在线观看视频| 激情图区综合网| 一区二区三区高清| 国产人成一区二区三区影院| 色婷婷精品大在线视频| 国产精品一区在线观看乱码| 亚洲成人7777| 亚洲日本欧美天堂| 久久久美女艺术照精彩视频福利播放| 91电影在线观看| 国产91露脸合集magnet| 美女mm1313爽爽久久久蜜臀| 亚洲人成在线播放网站岛国| 久久综合九色综合欧美就去吻| 在线观看av不卡| 99热99精品| 国产米奇在线777精品观看| 奇米一区二区三区| 亚洲丶国产丶欧美一区二区三区| 中文字幕一区二区在线播放 | 亚洲欧洲无码一区二区三区| 久久综合国产精品| 欧美一区二区性放荡片| 欧洲一区二区av| 91麻豆精东视频| 9i看片成人免费高清| 国产精品一区二区在线观看不卡 | 国产成+人+日韩+欧美+亚洲| 美女国产一区二区| 欧美bbbbb| 美女尤物国产一区| 蜜臀av亚洲一区中文字幕| 日本va欧美va欧美va精品| 三级成人在线视频| 日韩国产成人精品| 日韩国产精品久久久久久亚洲| 亚洲女子a中天字幕| 亚洲色大成网站www久久九九| 亚洲成a人v欧美综合天堂| 亚洲视频小说图片| 欧美亚洲国产一区二区三区va | 亚洲男女一区二区三区| 国产精品大尺度| 国产精品护士白丝一区av| 亚洲三级免费电影| 亚洲乱码一区二区三区在线观看| 亚洲欧美日韩国产综合| 亚洲综合色网站| 热久久一区二区| 国产在线精品一区在线观看麻豆| 国产一区二区三区四区五区入口 | 亚洲第一成人在线| 美腿丝袜亚洲综合| 国产黄色91视频| 99精品久久久久久| 欧美久久久久免费| 精品国产91九色蝌蚪| 日本一区二区不卡视频| 亚洲精品你懂的| 蜜臀av性久久久久蜜臀aⅴ流畅 | 欧美日韩国产a| 欧美xxxx在线观看| 中文字幕日本乱码精品影院| 亚洲自拍偷拍麻豆| 久久99久久精品| 99v久久综合狠狠综合久久| 欧美日韩国产小视频在线观看| 日韩一区二区三区av| 欧美国产一区二区| 亚洲国产精品一区二区尤物区| 免费不卡在线观看| 成人av影院在线| 欧美高清hd18日本| 国产精品久久久久久久久久久免费看 | 国产呦萝稀缺另类资源| 一本一本大道香蕉久在线精品| 91麻豆精品国产91久久久久久久久| 亚洲精品一区二区三区精华液| 中文字幕一区免费在线观看| 日精品一区二区三区| 成人av小说网| 精品国产乱子伦一区| 一区二区三区欧美久久| 国产精品一区二区三区99| 欧美精品日韩一区| 亚洲欧美另类图片小说| 国产精品伊人色| 日韩免费成人网| 亚洲第一狼人社区|