Comparable<Bin>
public class Bin extends Object implements Comparable<Bin>
Constructor | Description |
---|---|
Bin(int referenceSequence,
int binNumber) |
Modifier and Type | Method | Description |
---|---|---|
void |
addInitialChunk(Chunk newChunk) |
Adds the first chunk to the bin
|
int |
compareTo(Bin other) |
Compare two bins to see what ordering they should appear in.
|
boolean |
containsChunks() |
Returns whether the bin currently contains chunks.
|
boolean |
equals(Object other) |
See whether two bins are equal.
|
int |
getBinNumber() |
|
List<Chunk> |
getChunkList() |
Gets the list of chunks associated with this bin.
|
Chunk |
getLastChunk() |
Warning: Currently only valid during index building, not when reading existing index,
(AbstractBAMFileIndex.optimizeChunkList doesn't maintain this)
|
protected int |
getReferenceSequence() |
|
int |
hashCode() |
Compute a unique hash code for the given reference sequence and bin number.
|
void |
setChunkList(List<Chunk> list) |
Sets the chunks associated with this bin
|
void |
setLastChunk(Chunk c) |
Optimization to keep lastChunk instead of iterating over all chunks repeatedly
|
protected int getReferenceSequence()
public int getBinNumber()
public boolean equals(Object other)
public int hashCode()
public boolean containsChunks()
public int compareTo(Bin other)
compareTo
in interface Comparable<Bin>
other
- Other bin to which this bin should be compared.public void addInitialChunk(Chunk newChunk)
public List<Chunk> getChunkList()
public void setLastChunk(Chunk c)
public Chunk getLastChunk()