Modifier | Constructor and Description |
---|---|
protected |
FastaSequenceIndex()
Empty, protected constructor for unit testing.
|
|
FastaSequenceIndex(File indexFile)
Build a sequence index from the specified file.
|
|
FastaSequenceIndex(Path indexFile)
Build a sequence index from the specified file.
|
Modifier and Type | Method and Description |
---|---|
protected void |
add(htsjdk.samtools.reference.FastaSequenceIndexEntry indexEntry)
Add a new index entry to the list.
|
boolean |
equals(Object other)
Compare two FastaSequenceIndex objects for equality.
|
htsjdk.samtools.reference.FastaSequenceIndexEntry |
getIndexEntry(String contigName)
Retrieve the index entry associated with the given contig.
|
boolean |
hasIndexEntry(String contigName)
Does the given contig name have a corresponding entry?
|
Iterator<htsjdk.samtools.reference.FastaSequenceIndexEntry> |
iterator()
Creates an iterator which can iterate through all entries in a fasta index.
|
protected void |
rename(htsjdk.samtools.reference.FastaSequenceIndexEntry entry,
String newName)
Renames the existing index entry to the new index entry with the specified name.
|
int |
size()
Returns the number of elements in the index.
|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public FastaSequenceIndex(File indexFile)
indexFile
- File to open.FileNotFoundException
- if the index file cannot be found.public FastaSequenceIndex(Path indexFile)
indexFile
- File to open.FileNotFoundException
- if the index file cannot be found.protected FastaSequenceIndex()
protected void add(htsjdk.samtools.reference.FastaSequenceIndexEntry indexEntry)
indexEntry
- New index entry to add.protected void rename(htsjdk.samtools.reference.FastaSequenceIndexEntry entry, String newName)
entry
- entry to update.newName
- New name for the index entry.public boolean equals(Object other)
public boolean hasIndexEntry(String contigName)
contigName
- The contig name for which to search.public htsjdk.samtools.reference.FastaSequenceIndexEntry getIndexEntry(String contigName)
contigName
- Name of the contig for which to search.SAMException
- if the associated index entry can't be found.public Iterator<htsjdk.samtools.reference.FastaSequenceIndexEntry> iterator()
public int size()