# Interface Read

All Superinterfaces:
  `Fragment, FragmentIterator`

All Known Subinterfaces:
  `ReadIterator`

public interface Read extends FragmentIterator

## Field Summary

Fields
Modifier and Type
Field
Description
`static final int`
`aligned`
`static final int`
`all`
`static final int`
`fullyAligned`
ReadCategory
`static final int`
`partiallyAligned`
`static final int`
`unaligned`

## Method Summary

Modifier and Type
Method
Description
`boolean`
`fragmentIsAligned(int fragIdx)`
fragmentIsAligned
`int`
`getNumFragments()`
getNumFragments
`String`
`getReadBases()`
getReadBases
`String`
`getReadBases(long offset)`
getReadBases
`String`
`getReadBases(long offset, long length)`
getReadBases
`int`
`getReadCategory()`
getReadCategory
`String`
`getReadGroup()`
getReadGroup
`String`
`getReadId()`
getReadId
`String`
`getReadName()`
getReadName
`String`
`getReadQualities()`
getReadQualities
`String`
`getReadQualities(long offset)`
getReadQualities
`String`
`getReadQualities(long offset, long length)`
getReadQualities

### Methods inherited from interface Fragment

`getFragmentBases, getFragmentBases, getFragmentBases, getFragmentId, getFragmentQualities, getFragmentQualities, getFragmentQualities, isAligned, isPaired`

### Methods inherited from interface FragmentIterator

`nextFragment`

## Field Details

### fullyAligned

static final int fullyAligned
ReadCategory

See Also:
  - Constant Field Values

### partiallyAligned

static final int partiallyAligned

See Also:
  - Constant Field Values

### aligned

static final int aligned

See Also:
  - Constant Field Values

### unaligned

static final int unaligned

See Also:
  - Constant Field Values

### all

static final int all

See Also:
  - Constant Field Values

## Method Details

### getReadId

String getReadId() throws ErrorMsg
getReadId

Returns:
  the ID-String of the Read
Throws:
  `ErrorMsg` - upon an error accessing data

### getNumFragments

int getNumFragments() throws ErrorMsg
getNumFragments

Returns:
  the number of biological Fragments contained in the read
Throws:
  `ErrorMsg` - upon an error accessing data

### fragmentIsAligned

boolean fragmentIsAligned(int fragIdx) throws ErrorMsg
fragmentIsAligned

Parameters:
  `fragIdx` - is a zero-based and non-negative fragment index
Returns:
  true if a fragment is aligned
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadCategory

int getReadCategory() throws ErrorMsg
getReadCategory

Returns:
  the category of the read
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadGroup

String getReadGroup() throws ErrorMsg
getReadGroup

Returns:
  the read-group of the read
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadName

String getReadName() throws ErrorMsg
getReadName

Returns:
  the name of thethe read
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadBases

String getReadBases() throws ErrorMsg
getReadBases

Returns:
  sequence bases
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadBases

String getReadBases(long offset) throws ErrorMsg, IndexOutOfBoundsException
getReadBases

Parameters:
  `offset` - is zero-based and non-negative
Returns:
  sequence bases
Throws:
  `ErrorMsg` - upon an error accessing data
  `IndexOutOfBoundsException` - if offset is invalid

### getReadBases

String getReadBases(long offset, long length) throws ErrorMsg, IndexOutOfBoundsException
getReadBases

Parameters:
  `offset` - is zero-based and non-negative
  `length` - must be ≥ 0
Returns:
  sequence bases
Throws:
  `ErrorMsg` - upon an error accessing data
  `IndexOutOfBoundsException` - if offset/length are invalid

### getReadQualities

String getReadQualities() throws ErrorMsg
getReadQualities

Returns:
  phred quality values using ASCII offset of 33
Throws:
  `ErrorMsg` - upon an error accessing data

### getReadQualities

String getReadQualities(long offset) throws ErrorMsg, IndexOutOfBoundsException
getReadQualities

Parameters:
  `offset` - is zero-based and non-negative
Returns:
  phred quality values using ASCII offset of 33
Throws:
  `ErrorMsg` - upon an error accessing data
  `IndexOutOfBoundsException` - if offset is invalid

### getReadQualities

String getReadQualities(long offset, long length) throws ErrorMsg, IndexOutOfBoundsException
getReadQualities

Parameters:
  `offset` - is zero-based and non-negative
  `length` - must be ≥ 0
Returns:
  phred quality values using ASCII offset of 33
Throws:
  `ErrorMsg` - upon an error accessing data
  `IndexOutOfBoundsException` - if offset/length are invalid