Class BAMSBIIndexer


  • public final class BAMSBIIndexer
    extends Object
    Writes SBI files for BAM files, as understood by SBIIndex.
    • Constructor Detail

      • BAMSBIIndexer

        public BAMSBIIndexer()
    • Method Detail

      • createIndex

        public static void createIndex​(Path bamFile,
                                       long granularity)
                                throws IOException
        Perform indexing on the given BAM file, at the granularity level specified.
        Parameters:
        bamFile - the path to the BAM file
        granularity - write the offset of every n-th alignment to the index
        Throws:
        IOException - as per java IO contract
      • createIndex

        public static void createIndex​(SeekableStream in,
                                       OutputStream out,
                                       long granularity)
                                throws IOException
        Perform indexing on the given BAM file, at the granularity level specified.
        Parameters:
        in - a seekable stream for reading the BAM file from
        out - the stream to write the index to
        granularity - write the offset of every n-th alignment to the index
        Throws:
        IOException - as per java IO contract