提交 f828d1b3 编写于 作者: H Hongze Cheng

more refact

上级 af1724fb
...@@ -83,18 +83,16 @@ int32_t tTABLEIDCmprFn(const void *p1, const void *p2); ...@@ -83,18 +83,16 @@ int32_t tTABLEIDCmprFn(const void *p1, const void *p2);
// TSDBKEY // TSDBKEY
int32_t tsdbKeyCmprFn(const void *p1, const void *p2); int32_t tsdbKeyCmprFn(const void *p1, const void *p2);
// KEYINFO // KEYINFO
#define tKEYINFOInit() \ #define tKEYINFOInit() \
((KEYINFO){.maxKey = {.ts = TSKEY_MIN, .version = 0}, \ ((KEYINFO){.maxKey = {.ts = TSKEY_MIN, .version = -1}, \
.minKey = {.ts = TSKEY_MAX, .version = -1}, \ .minKey = {.ts = TSKEY_MAX, .version = INT64_MAX}, \
.minVerion = INT64_MAX, \ .minVerion = INT64_MAX, \
.maxKey = -1}) .maxVersion = -1})
int32_t tPutKEYINFO(uint8_t *p, KEYINFO *pKeyInfo); int32_t tPutKEYINFO(uint8_t *p, KEYINFO *pKeyInfo);
int32_t tGetKEYINFO(uint8_t *p, KEYINFO *pKeyInfo); int32_t tGetKEYINFO(uint8_t *p, KEYINFO *pKeyInfo);
// SColdata // SBlockCol
int32_t tColDataCmprFn(const void *p1, const void *p2); int32_t tPutBlockCol(uint8_t *p, void *ph);
// SBlockIdx int32_t tGetBlockCol(uint8_t *p, void *ph);
int32_t tPutBlockIdx(uint8_t *p, void *ph);
int32_t tGetBlockIdx(uint8_t *p, void *ph);
// SBlock // SBlock
#define tBlockInit() ((SBlock){.info = tKEYINFOInit()}) #define tBlockInit() ((SBlock){.info = tKEYINFOInit()})
void tBlockReset(SBlock *pBlock); void tBlockReset(SBlock *pBlock);
...@@ -102,9 +100,14 @@ void tBlockClear(SBlock *pBlock); ...@@ -102,9 +100,14 @@ void tBlockClear(SBlock *pBlock);
int32_t tPutBlock(uint8_t *p, void *ph); int32_t tPutBlock(uint8_t *p, void *ph);
int32_t tGetBlock(uint8_t *p, void *ph); int32_t tGetBlock(uint8_t *p, void *ph);
int32_t tBlockCmprFn(const void *p1, const void *p2); int32_t tBlockCmprFn(const void *p1, const void *p2);
// SBlockCol // SBlockIdx
int32_t tPutBlockCol(uint8_t *p, void *ph); int32_t tPutBlockIdx(uint8_t *p, void *ph);
int32_t tGetBlockCol(uint8_t *p, void *ph); int32_t tGetBlockIdx(uint8_t *p, void *ph);
// SColdata
#define tColDataInit() ((SColData){0})
void tColDataReset(SColData *pColData);
void tColDataClear(SColData *pColData);
int32_t tColDataCmprFn(const void *p1, const void *p2);
// SBlockData // SBlockData
#define tsdbBlockDataCreate() ((SBlockData){0}) #define tsdbBlockDataCreate() ((SBlockData){0})
void tsdbBlockDataClear(SBlockData *pBlockData); void tsdbBlockDataClear(SBlockData *pBlockData);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册