Search in sources :

Example 1 with EvidenceSource

use of au.edu.wehi.idsv.EvidenceSource in project gridss by PapenfussLab.

the class KmerEvidence method getReferenceContigLength.

/**
 * Finds the length of the reference sequence on which this kmer is placed
 * @param e
 * @return
 */
private static int getReferenceContigLength(DirectedEvidence e) {
    int refIndex = e.getBreakendSummary().referenceIndex;
    EvidenceSource source = e.getEvidenceSource();
    if (source != null) {
        ProcessingContext context = source.getContext();
        if (context != null) {
            return context.getReference().getSequenceDictionary().getSequence(refIndex).getSequenceLength();
        }
    }
    return Integer.MAX_VALUE;
}
Also used : ProcessingContext(au.edu.wehi.idsv.ProcessingContext) EvidenceSource(au.edu.wehi.idsv.EvidenceSource)

Aggregations

EvidenceSource (au.edu.wehi.idsv.EvidenceSource)1 ProcessingContext (au.edu.wehi.idsv.ProcessingContext)1