Package ngs

# Interface Fragment

All Known Subinterfaces:
  `Alignment`, `AlignmentIterator`, `FragmentIterator`, `Read`, `ReadIterator`

public interface Fragment
Represents an NGS biological fragment

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getFragmentBases()`
  getFragmentBases
  `String`
  `getFragmentBases(long offset)`
  getFragmentBases
  `String`
  `getFragmentBases(long offset, long length)`
  getFragmentBases
  `String`
  `getFragmentId()`
  getFragmentId
  `String`
  `getFragmentQualities()`
  getFragmentQualities using ASCII offset of 33
  `String`
  `getFragmentQualities(long offset)`
  getFragmentQualities using ASCII offset of 33
  `String`
  `getFragmentQualities(long offset, long length)`
  getFragmentQualities using ASCII offset of 33
  `boolean`
  `isAligned()`
  check to see if Fragment has alignment data (requires interface 1.1)
  `boolean`
  `isPaired()`
  isPaired

- ## Method Details

  - ### getFragmentId

    String getFragmentId() throws ErrorMsg
    getFragmentId
    Returns:
      the unique ID of the fragment
    Throws:
      `ErrorMsg` - upon an error accessing data

  - ### getFragmentBases

    String getFragmentBases() throws ErrorMsg
    getFragmentBases
    Returns:
      sequence bases
    Throws:
      `ErrorMsg` - upon an error accessing data

  - ### getFragmentBases

    String getFragmentBases(long offset) throws ErrorMsg, IndexOutOfBoundsException
    getFragmentBases
    Parameters:
      `offset` - is zero-based and non-negative
    Returns:
      sequence bases
    Throws:
      `ErrorMsg` - upon an error accessing data
      `IndexOutOfBoundsException` - upon invalid offset

  - ### getFragmentBases

    String getFragmentBases(long offset, long length) throws ErrorMsg, IndexOutOfBoundsException
    getFragmentBases
    Parameters:
      `offset` - is zero-based and non-negative
      `length` - must be ≥ 0
    Returns:
      sequence bases
    Throws:
      `ErrorMsg` - upon an error accessing data
      `IndexOutOfBoundsException` - upon invalid offset

  - ### getFragmentQualities

    String getFragmentQualities() throws ErrorMsg
    getFragmentQualities using ASCII offset of 33
    Returns:
      phred quality values for the whole fragment
    Throws:
      `ErrorMsg` - upon an error accessing data

  - ### getFragmentQualities

    String getFragmentQualities(long offset) throws ErrorMsg, IndexOutOfBoundsException
    getFragmentQualities using ASCII offset of 33
    Parameters:
      `offset` - is zero-based and non-negative
    Returns:
      phred quality values
    Throws:
      `ErrorMsg` - upon an error accessing data
      `IndexOutOfBoundsException` - upon invalid offset

  - ### getFragmentQualities

    String getFragmentQualities(long offset, long length) throws ErrorMsg, IndexOutOfBoundsException
    getFragmentQualities using ASCII offset of 33
    Parameters:
      `offset` - is zero-based and non-negative
      `length` - must be ≥ 0
    Returns:
      phred quality values
    Throws:
      `ErrorMsg` - upon an error accessing data
      `IndexOutOfBoundsException` - upon invalid offset/length

  - ### isPaired

    boolean isPaired() throws ErrorMsg
    isPaired
    Returns:
      true if fragment has a mate
    Throws:
      `ErrorMsg` - upon an error accessing data

  - ### isAligned

    boolean isAligned() throws ErrorMsg
    check to see if Fragment has alignment data (requires interface 1.1)
    Returns:
      true if Fragment is aligned
    Throws:
      `ErrorMsg` - if object is invalid or implementation too old