Package ngs

Interface Alignment

All Superinterfaces:
Fragment
All Known Subinterfaces:
AlignmentIterator

public interface Alignment extends Fragment
Represents an alignment between a Fragment and Reference sub-sequence provides a path to Read and mate Alignment
  • Field Details

  • Method Details

    • getAlignmentId

      String getAlignmentId() throws ErrorMsg
      Retrieve an identifying String that can be used for later access. The id will be unique within ReadCollection.
      Returns:
      alignment id
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getReferenceSpec

      String getReferenceSpec() throws ErrorMsg
      getReferenceSpec
      Returns:
      the name of the reference
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getMappingQuality

      int getMappingQuality() throws ErrorMsg
      getMappingQuality
      Returns:
      mapping quality
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getReferenceBases

      String getReferenceBases() throws ErrorMsg
      getReferenceBases
      Returns:
      reference bases
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getReadGroup

      String getReadGroup() throws ErrorMsg
      getReadGroup
      Returns:
      the name of the read-group
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getReadId

      String getReadId() throws ErrorMsg
      getReadId
      Returns:
      the unique name of the read
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getClippedFragmentBases

      String getClippedFragmentBases() throws ErrorMsg
      getClippedFragmentBases
      Returns:
      clipped fragment bases
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getClippedFragmentQualities

      String getClippedFragmentQualities() throws ErrorMsg
      getClippedFragmentQualities
      Returns:
      clipped fragment phred quality values using ASCII offset of 33
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getAlignedFragmentBases

      String getAlignedFragmentBases() throws ErrorMsg
      getAlignedFragmentBases
      Returns:
      fragment bases in their aligned orientation
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getAlignmentCategory

      int getAlignmentCategory() throws ErrorMsg
      Alignments are categorized as primary or secondary (alternate).
      Returns:
      either Alignment.primaryAlignment or Alignment.secondaryAlignment
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getAlignmentPosition

      long getAlignmentPosition() throws ErrorMsg
      Retrieve the Alignment's starting position on the Reference
      Returns:
      unsigned 0-based offset from start of Reference
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getAlignmentLength

      long getAlignmentLength() throws ErrorMsg
      Retrieve the projected length of an Alignment projected upon Reference.
      Returns:
      unsigned length of projection
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getIsReversedOrientation

      boolean getIsReversedOrientation() throws ErrorMsg
      Test if orientation is reversed with respect to the Reference sequence.
      Returns:
      true if reversed
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getSoftClip

      int getSoftClip(int edge) throws ErrorMsg
      getSoftClip
      Parameters:
      edge - which edge
      Returns:
      the position of the clipping
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getTemplateLength

      long getTemplateLength() throws ErrorMsg
      getTemplateLength
      Returns:
      the lenght of the template
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getShortCigar

      String getShortCigar(boolean clipped) throws ErrorMsg
      getShortCigar
      Parameters:
      clipped - selects if clipping has to be applied
      Returns:
      a text string describing alignment details
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getLongCigar

      String getLongCigar(boolean clipped) throws ErrorMsg
      getLongCigar
      Parameters:
      clipped - selects if clipping has to be applied
      Returns:
      a text string describing alignment details
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getRNAOrientation

      char getRNAOrientation() throws ErrorMsg
      getRNAOrientation
      Returns:
      '+' if positive strand is transcribed; '-' if negative strand is transcribed; '?' if unknown
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • hasMate

      boolean hasMate()
      hasMate
      Returns:
      if the alignment has a mate
    • getMateAlignmentId

      String getMateAlignmentId() throws ErrorMsg
      getMateAlignmentId
      Returns:
      unique ID of th alignment
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getMateAlignment

      Alignment getMateAlignment() throws ErrorMsg
      getMateAlignment
      Returns:
      the mate as alignment
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getMateReferenceSpec

      String getMateReferenceSpec() throws ErrorMsg
      getMateReferenceSpec
      Returns:
      the name of the reference the mate is aligned at
      Throws:
      ErrorMsg - if the property cannot be retrieved
    • getMateIsReversedOrientation

      boolean getMateIsReversedOrientation() throws ErrorMsg
      getMateIsReversedOrientation
      Returns:
      the orientation of the mate
      Throws:
      ErrorMsg - if the property cannot be retrieved