Package net.sf.samtools.util

Examples of net.sf.samtools.util.SeekableStream.seek()


    } else if (is instanceof SeekableStream)
      s = (SeekableStream) is;

    SAMIterator si = null;
    try {
      s.seek(0);
      si = new SAMIterator(s, referenceSequenceFile);
      si.setValidationStringency(validationStringency);
      it = si;
    } catch (IOException e) {
      throw new RuntimeEOFException(e);
View Full Code Here


    Container c = null;
    for (int i = 0; i < filePointers.length; i += 2) {
      long containerOffset = filePointers[i] >>> 16;
      int sliceIndex = (int) ((filePointers[i] << 48) >>> 48);
      try {
        s.seek(containerOffset);
        // the following is not optimal because this is container-level
        // access, not slice:

        // CountingInputStream cis = new CountingInputStream(s) ;
        c = ReadWrite.readContainerHeader(s);
View Full Code Here

        // CountingInputStream cis = new CountingInputStream(s) ;
        c = ReadWrite.readContainerHeader(s);
        // long headerSize = cis.getCount() ;
        // int sliceOffset = c.landmarks[sliceIndex] ;
        if (c.alignmentStart + c.alignmentSpan > start) {
          s.seek(containerOffset);
          // s.seek(containerOffset + headerSize + sliceOffset);
          return si;
        }
      } catch (IOException e) {
        throw new RuntimeException(e);
View Full Code Here

    } else if (is instanceof SeekableStream)
      s = (SeekableStream) is;

    SAMIterator si = null;
    try {
      s.seek(0);
      si = new SAMIterator(s, referenceSequenceFile);
      si.setValidationStringency(validationStringency);
      s.seek(startOfLastLinearBin);
      it = si;
    } catch (IOException e) {
View Full Code Here

    SAMIterator si = null;
    try {
      s.seek(0);
      si = new SAMIterator(s, referenceSequenceFile);
      si.setValidationStringency(validationStringency);
      s.seek(startOfLastLinearBin);
      it = si;
    } catch (IOException e) {
      throw new RuntimeEOFException(e);
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.