public final class MultiDeBruijnVertex extends BaseVertex
sequence
Constructor and Description |
---|
MultiDeBruijnVertex(byte[] sequence)
Create a new MultiDeBruijnVertex with kmer sequence
|
MultiDeBruijnVertex(byte[] sequence,
boolean mergeIdenticalNodes)
Create a new MultiDeBruijnVertex with kmer sequence
|
Modifier and Type | Method and Description |
---|---|
void |
addRead(java.lang.String name)
Add name information to this vertex for debugging
This information will be captured as a list of strings, and displayed in DOT if this
graph is written out to disk
This functionality is only enabled when KEEP_TRACK_OF_READS is true
|
boolean |
equals(java.lang.Object o) |
java.lang.String |
getAdditionalInfo() |
byte[] |
getAdditionalSequence(boolean source)
Get the sequence unique to this vertex
This function may not return the entire sequence stored in the vertex, as kmer graphs
really only provide 1 base of additional sequence (the last base of the kmer).
|
int |
getKmerSize()
Get the kmer size for this DeBruijnVertex
|
byte |
getSuffix()
Get the suffix byte of this DeBruijnVertex
The suffix byte is simply the last byte of the kmer sequence, so if this is holding sequence ACT
getSuffix would return T
|
java.lang.String |
getSuffixString()
Get the string representation of the suffix of this DeBruijnVertex
|
int |
hashCode()
necessary to override here so that graph.containsVertex() works the same way as vertex.equals() as one might expect
|
java.lang.String |
toString() |
getSequence, getSequenceString, hasAmbiguousSequence, isEmpty, length, seqEquals, setAdditionalInfo
public MultiDeBruijnVertex(byte[] sequence, boolean mergeIdenticalNodes)
mergeIdenticalNodes
- should nodes with the same sequence be treated as equal?sequence
- the kmer sequencepublic MultiDeBruijnVertex(byte[] sequence)
sequence
- the kmer sequencepublic boolean equals(java.lang.Object o)
equals
in class BaseVertex
public int hashCode()
BaseVertex
hashCode
in class BaseVertex
public java.lang.String toString()
toString
in class BaseVertex
public void addRead(java.lang.String name)
name
- a non-null stringpublic java.lang.String getAdditionalInfo()
getAdditionalInfo
in class BaseVertex
public int getKmerSize()
public java.lang.String getSuffixString()
public byte getSuffix()
public byte[] getAdditionalSequence(boolean source)
getAdditionalSequence
in class BaseVertex
source
- is this vertex a source vertex (i.e., no in nodes) in the graph