提交 0ef7eec7 编写于 作者: H Hongze Cheng

more work

上级 c000c15e
......@@ -34,8 +34,6 @@ typedef struct SValue SValue;
typedef struct SColVal SColVal;
typedef struct STSRow2 STSRow2;
typedef struct STSRowBuilder STSRowBuilder;
typedef struct SColData SColData;
typedef struct SColDataBatch SColDataBatch;
typedef struct STagVal STagVal;
typedef struct STag STag;
......@@ -171,17 +169,6 @@ struct STag {
};
#pragma pack(pop)
struct SColData {
int16_t cid;
uint32_t nData;
uint8_t *pData;
};
struct SColDataBatch {
uint8_t flags;
SColData *aColData[];
};
#if 1 //================================================================================================================================================
// Imported since 3.0 and use bitmap to demonstrate None/Null/Norm, while use Null/Norm below 3.0 without of bitmap.
#define TD_SUPPORT_BITMAP
......
......@@ -155,7 +155,8 @@ int32_t tTABLEIDCmprFn(const void *p1, const void *p2);
int32_t tsdbKeyCmprFn(const void *p1, const void *p2);
// SMapData
int32_t tMapDataClear(SMapData *pMapData);
void tMapDataReset(SMapData *pMapData);
void tMapDataClear(SMapData *pMapData);
int32_t tMapDataPutItem(SMapData *pMapData, void *pItem, int32_t (*tPutItemFn)(uint8_t *, void *));
int32_t tMapDataGetItemByIdx(SMapData *pMapData, int32_t idx, void *pItem, int32_t (*tGetItemFn)(uint8_t *, void *));
int32_t tPutMapData(uint8_t *p, SMapData *pMapData);
......@@ -449,8 +450,7 @@ struct SMapData {
};
struct SVDataCols {
int64_t *aVersion;
SDataCols dataCols;
int64_t *aVersion;
};
#ifdef __cplusplus
......
......@@ -131,13 +131,15 @@ static FORCE_INLINE int32_t tGetOffset(uint8_t *p, SOffset *pOfst) {
}
// SMapData =======================================================================
int32_t tMapDataClear(SMapData *pMapData) {
int32_t code = 0;
void tMapDataReset(SMapData *pMapData) {
pMapData->flag = TSDB_OFFSET_I32;
pMapData->nItem = 0;
pMapData->nData = 0;
}
void tMapDataClear(SMapData *pMapData) {
tsdbFree(pMapData->pOfst);
tsdbFree(pMapData->pData);
return code;
}
int32_t tMapDataPutItem(SMapData *pMapData, void *pItem, int32_t (*tPutItemFn)(uint8_t *, void *)) {
......@@ -722,4 +724,6 @@ int32_t tsdbKeyFid(TSKEY key, int32_t minutes, int8_t precision) {
} else {
return (int)((key / tsTickPerMin[precision] / minutes));
}
}
\ No newline at end of file
}
// SColDataBlock ======================================================
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册