Package io.trino.orc
Class CachingOrcDataSource
- java.lang.Object
-
- io.trino.orc.CachingOrcDataSource
-
- All Implemented Interfaces:
OrcDataSource,Closeable,AutoCloseable
public class CachingOrcDataSource extends Object implements OrcDataSource
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceCachingOrcDataSource.RegionFinder
-
Constructor Summary
Constructors Constructor Description CachingOrcDataSource(OrcDataSource dataSource, CachingOrcDataSource.RegionFinder regionFinder)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()longgetEstimatedSize()OrcDataSourceIdgetId()longgetReadBytes()longgetReadTimeNanos()longgetRetainedSize()Gets the memory size of this data source.io.airlift.slice.SlicereadFully(long position, int length)<K> Map<K,OrcDataReader>readFully(Map<K,DiskRange> diskRanges)io.airlift.slice.SlicereadTail(int length)StringtoString()
-
-
-
Constructor Detail
-
CachingOrcDataSource
public CachingOrcDataSource(OrcDataSource dataSource, CachingOrcDataSource.RegionFinder regionFinder)
-
-
Method Detail
-
getId
public OrcDataSourceId getId()
- Specified by:
getIdin interfaceOrcDataSource
-
getReadBytes
public long getReadBytes()
- Specified by:
getReadBytesin interfaceOrcDataSource
-
getReadTimeNanos
public long getReadTimeNanos()
- Specified by:
getReadTimeNanosin interfaceOrcDataSource
-
getEstimatedSize
public long getEstimatedSize()
- Specified by:
getEstimatedSizein interfaceOrcDataSource
-
getRetainedSize
public long getRetainedSize()
Description copied from interface:OrcDataSourceGets the memory size of this data source. This only includes memory used for the data source and not memory assigned to a specific OrcDataReader.- Specified by:
getRetainedSizein interfaceOrcDataSource
-
readTail
public io.airlift.slice.Slice readTail(int length)
- Specified by:
readTailin interfaceOrcDataSource
-
readFully
public io.airlift.slice.Slice readFully(long position, int length) throws IOException- Specified by:
readFullyin interfaceOrcDataSource- Throws:
IOException
-
readFully
public <K> Map<K,OrcDataReader> readFully(Map<K,DiskRange> diskRanges) throws IOException
- Specified by:
readFullyin interfaceOrcDataSource- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceOrcDataSource- Throws:
IOException
-
-