[IOTDB-6325] Support RegionScan for active metadata queries [BE Part One]
If we want to find the metaData which is activate during a period of time, we need to scan the raw data. Current implementation of seriesScan may cause random access due to the access to one TSFile repeatedly. We could use file scan to eliminate this. Region scan is the feature in IoTDB to support fileScan, this PR would support basic FileHandle for TsFile which support file-based scanning.
FileScanHandle corresponds to a TsFile and is used for related metadata operations and data scanning on the TsFile; ChunkHandle corresponds to specific chunk data, and we can obtain a batch of ChunkHandle for sequential scanning through the interface of FileScanHandle.
The relationship between the related classes is shown in the following diagram.TsFileResource is original implementation. Among red ones, DiskChunkHandle is used to access chunks on the disk, while MemChunkHandle is used to access data in the MemTable. Due to the possibility of partially flushed MemTables, UnclosedFileScanHandle will include both of these scenarios.