提交 9916d248 编写于 作者: H Hongze Cheng

more refact

上级 1e5c2688
......@@ -42,7 +42,7 @@ static void tdbPCachePinPage(SPgHdr *pPage);
static void tdbPCacheRemovePageFromHash(SPgHdr *pPage);
static void tdbPCacheAddPageToHash(SPgHdr *pPage);
int tdbOpenPCache(int pageSize, int cacheSize, int extraSize, SPCache **ppCache) {
int tdbPCacheOpen(int pageSize, int cacheSize, int extraSize, SPCache **ppCache) {
SPCache *pCache;
void * pPtr;
SPgHdr * pPgHdr;
......@@ -74,7 +74,7 @@ int tdbOpenPCache(int pageSize, int cacheSize, int extraSize, SPCache **ppCache)
return 0;
}
int tdbClosePCache(SPCache *pCache) {
int tdbPCacheClose(SPCache *pCache) {
/* TODO */
return 0;
}
......
......@@ -36,7 +36,7 @@ struct SPgHdr {
SPgHdr * pLruPrev;
};
int tdbOpenPCache(int pageSize, int cacheSize, int extraSize, SPCache **ppCache);
int tdbPCacheOpen(int pageSize, int cacheSize, int extraSize, SPCache **ppCache);
int tdbPCacheClose(SPCache *pCache);
SPgHdr *tdbPCacheFetch(SPCache *pCache, const SPgid *pPgid, bool alcNewPage);
void tdbFetchFinish(SPCache *pCache, SPgHdr *pPage);
......
......@@ -20,6 +20,8 @@
extern "C" {
#endif
typedef struct SPFile SPFile;
// typedef struct __attribute__((__packed__)) {
// char hdrInfo[16]; // info string
// pgsz_t szPage; // page size of current file
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册