public class TabixFeatureReader<T extends Feature,SOURCE> extends AbstractFeatureReader<T,SOURCE>
AbstractFeatureReader.ComponentMethodsBLOCK_COMPRESSED_EXTENSIONS, codec, header| Constructor and Description |
|---|
TabixFeatureReader(java.lang.String featureFile,
AsciiFeatureCodec codec) |
TabixFeatureReader(java.lang.String featureFile,
java.lang.String indexFile,
AsciiFeatureCodec codec) |
TabixFeatureReader(java.lang.String featureFile,
java.lang.String indexFile,
AsciiFeatureCodec codec,
java.util.function.Function<java.nio.channels.SeekableByteChannel,java.nio.channels.SeekableByteChannel> wrapper,
java.util.function.Function<java.nio.channels.SeekableByteChannel,java.nio.channels.SeekableByteChannel> indexWrapper) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the reader
|
java.util.List<java.lang.String> |
getSequenceNames()
Provides the list of sequenceNames if known.
|
boolean |
hasIndex()
Whether the reader has an index or not
Default implementation returns false
|
CloseableTribbleIterator<T> |
iterator()
Provides access to all the features in the reader
|
CloseableTribbleIterator<T> |
query(java.lang.String chr,
int start,
int end)
Return iterator over all features overlapping the given interval
|
getFeatureReader, getFeatureReader, getFeatureReader, getFeatureReader, getFeatureReader, getHeader, hasBlockCompressedExtension, hasBlockCompressedExtension, hasBlockCompressedExtension, isQueryable, isTabix, setComponentMethodsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitquerypublic TabixFeatureReader(java.lang.String featureFile,
AsciiFeatureCodec codec)
throws java.io.IOException
featureFile - - path to a feature file. Can be a local file, http url, or ftp urlcodec - java.io.IOExceptionpublic TabixFeatureReader(java.lang.String featureFile,
java.lang.String indexFile,
AsciiFeatureCodec codec)
throws java.io.IOException
featureFile - - path to a feature file. Can be a local file, http url, or ftp urlindexFile - - path to the index file.codec - java.io.IOExceptionpublic TabixFeatureReader(java.lang.String featureFile,
java.lang.String indexFile,
AsciiFeatureCodec codec,
java.util.function.Function<java.nio.channels.SeekableByteChannel,java.nio.channels.SeekableByteChannel> wrapper,
java.util.function.Function<java.nio.channels.SeekableByteChannel,java.nio.channels.SeekableByteChannel> indexWrapper)
throws java.io.IOException
featureFile - path to a feature file. Can be a local file, http url, or ftp urlindexFile - path to the index file.wrapper - a wrapper to apply to the byte stream from the featureResource allowing injecting features
like caching and prefetching of the stream, may be null, will only be applied if featureFile
is a uri representing a PathindexWrapper - a wrapper to apply to the byte stream from the indexResource, may be null, will only be
applied if indexFile is a uri representing a Pathjava.io.IOExceptionpublic boolean hasIndex()
AbstractFeatureReaderhasIndex in class AbstractFeatureReader<T extends Feature,SOURCE>public java.util.List<java.lang.String> getSequenceNames()
FeatureReaderpublic CloseableTribbleIterator<T> query(java.lang.String chr, int start, int end) throws java.io.IOException
chr - start - end - java.io.IOExceptionpublic CloseableTribbleIterator<T> iterator() throws java.io.IOException
FeatureReaderjava.io.IOException - If there's a problem reading.public void close()
throws java.io.IOException
FeatureReaderjava.io.IOException