Class OutputMapping


  • public class OutputMapping
    extends Object
    In multiple locations we need to know what cycles are output, as of now we output all non-skip cycles, but rather than sprinkle this knowledge throughout the parser code, instead OutputMapping provides all the data a client might want about the cycles to be output including what ReadType they are.
    • Constructor Detail

      • OutputMapping

        public OutputMapping​(ReadStructure readStructure)
        Create an OutputMapping from a readStructure, currently the outputSubstructure just references the readStructure.nonSkips Substructure
        Parameters:
        readStructure - The readStructure for the given run that we want an OutputMapping for
    • Method Detail

      • numOutputReads

        public int numOutputReads()
        Returns:
        The number of reads that should be found in the output clusterData
      • getOutputCycles

        public int[] getOutputCycles()
        Returns:
        An array of cycles in ascending order of all the cycles that should be output.
      • getOutputReadLengths

        public int[] getOutputReadLengths()
        Returns:
        An ordered array of lengths, where each element represents the size of output reads respectively
      • getTotalOutputCycles

        public int getTotalOutputCycles()
        Returns:
        The total number of cycles that will be output
      • getCycleIndexRanges

        public Range[] getCycleIndexRanges()
        Returns:
        An ordered array of Ranges over cycle indices(cycle#-1), where each range represents a contiguous block of cycles to output, and each cycle in getOutputCycles() is in ONE AND ONLY ONE Range, all ranges are inclusive of both ends
      • getOutputDescriptors

        public Iterable<ReadDescriptor> getOutputDescriptors()
        Returns:
        An iterator over the read descriptors that describe the reads to be output
      • getOutputReadStructure

        public ReadStructure getOutputReadStructure()
      • getOutputIndexForCycle

        public picard.illumina.parser.OutputMapping.TwoDIndex getOutputIndexForCycle​(int cycle)
        Return an index that where: index.arrayIndex - represents either the read number the cycle will be output too, or (in some cases) an array index into a two dimensional array of byte[][] where the top level array corresponds to read number index.elementIndex - represents the element a cycle will appear in inside it's give read, or the element in an array as described above
        Parameters:
        cycle - The cycle for which we want an index
        Returns:
        A TwoDArrayIndex indicating where this cycle can be found