Class SeriesReaderByTimestamp
- java.lang.Object
-
- org.apache.iotdb.db.query.reader.series.SeriesReaderByTimestamp
-
- All Implemented Interfaces:
IReaderByTimestamp
public class SeriesReaderByTimestamp extends java.lang.Object implements IReaderByTimestamp
-
-
Constructor Summary
Constructors Constructor Description SeriesReaderByTimestamp(org.apache.iotdb.commons.path.PartialPath seriesPath, java.util.Set<java.lang.String> allSensors, org.apache.iotdb.tsfile.file.metadata.enums.TSDataType dataType, QueryContext context, java.util.List<TsFileResource> seqFileResource, java.util.List<TsFileResource> unseqFileResource, boolean ascending)SeriesReaderByTimestamp(org.apache.iotdb.commons.path.PartialPath seriesPath, java.util.Set<java.lang.String> allSensors, org.apache.iotdb.tsfile.file.metadata.enums.TSDataType dataType, QueryContext context, QueryDataSource dataSource, TsFileFilter fileFilter, boolean ascending)SeriesReaderByTimestamp(SeriesReader seriesReader, boolean ascending)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object[]getValuesInTimestamps(long[] timestamps, int length)Returns the corresponding value under this timestamp.protected booleanhasNext(long timestamp)booleanreaderIsEmpty()Returns whether there is no more data in reader.
-
-
-
Constructor Detail
-
SeriesReaderByTimestamp
public SeriesReaderByTimestamp(org.apache.iotdb.commons.path.PartialPath seriesPath, java.util.Set<java.lang.String> allSensors, org.apache.iotdb.tsfile.file.metadata.enums.TSDataType dataType, QueryContext context, QueryDataSource dataSource, TsFileFilter fileFilter, boolean ascending)
-
SeriesReaderByTimestamp
public SeriesReaderByTimestamp(SeriesReader seriesReader, boolean ascending)
-
SeriesReaderByTimestamp
public SeriesReaderByTimestamp(org.apache.iotdb.commons.path.PartialPath seriesPath, java.util.Set<java.lang.String> allSensors, org.apache.iotdb.tsfile.file.metadata.enums.TSDataType dataType, QueryContext context, java.util.List<TsFileResource> seqFileResource, java.util.List<TsFileResource> unseqFileResource, boolean ascending)
-
-
Method Detail
-
getValuesInTimestamps
public java.lang.Object[] getValuesInTimestamps(long[] timestamps, int length) throws java.io.IOExceptionDescription copied from interface:IReaderByTimestampReturns the corresponding value under this timestamp. Returns null if no value under this timestamp.Note that calling this method will change the status of this reader irreversibly just like
next. The difference is thatnextmoves one step forward whilegetValueInTimestampadvances towards the given timestamp.Attention: DO call this method with monotonically increasing timestamps. There is no guarantee of correctness with any other way of calling. For example, DO NOT call this method twice with the same timestamp.
- Specified by:
getValuesInTimestampsin interfaceIReaderByTimestamp- Throws:
java.io.IOException
-
readerIsEmpty
public boolean readerIsEmpty() throws java.io.IOExceptionDescription copied from interface:IReaderByTimestampReturns whether there is no more data in reader.True means no more data. False means you can still get more data
- Specified by:
readerIsEmptyin interfaceIReaderByTimestamp- Throws:
java.io.IOException
-
hasNext
protected boolean hasNext(long timestamp) throws java.io.IOException- Throws:
java.io.IOException
-
-