Package org.snpeff.binseq

# Class DnaSequenceId

java.lang.Object
org.snpeff.binseq.BinarySequence
org.snpeff.binseq.DnaSequence
org.snpeff.binseq.DnaSequenceId

All Implemented Interfaces:
  `Serializable`, `Cloneable`, `Comparable<BinarySequence>`

public class DnaSequenceId extends DnaSequence
Binary packed DNA sequence with an ID (long)

Author:
  pcingola
See Also:
  - Serialized Form

## Constructor Summary

Constructors
Constructor
Description
`DnaSequenceId(long id, int length, long[] codes)`
`DnaSequenceId(long id, String seqStr)`
`DnaSequenceId(String seqStr)`

## Method Summary

Modifier and Type
Method
Description
`static DnaSequenceId`
`empty()`
Empty sequence singleton
`protected DnaSequence`
`factory()`
Create sequences
`long`
`getId()`
`BinarySequence`
`read(DataInputStream dataInStream)`
Read data in binary format
`protected void`
`readDataStream(DataInputStream dataInStream)`
Read data in binary format
`String`
`toString()`
`void`
`write(DataOutputStream dataOutStream)`
Write data in binary format

### Methods inherited from class org.snpeff.binseq.DnaSequence

`clone, compareTo, getBase, getBases, getCode, getCoder, getCodes, getSequence, hashCode, isEmpty, length, overlap, reverseWc, set, set, setBase, setCodes`

### Methods inherited from class org.snpeff.binseq.BinarySequence

`setQuality`

### Methods inherited from class java.lang.Object

`equals, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Constructor Details

### DnaSequenceId

public DnaSequenceId(long id, int length, long[] codes)

### DnaSequenceId

public DnaSequenceId(long id, String seqStr)

### DnaSequenceId

public DnaSequenceId(String seqStr)

## Method Details

### empty

public static DnaSequenceId empty()
Empty sequence singleton

Returns:

### factory

protected DnaSequence factory()
Create sequences

Overrides:
  `factory` in class `DnaSequence`
Returns:

### getId

public long getId()

### read

public BinarySequence read(DataInputStream dataInStream) throws IOException
Read data in binary format

Overrides:
  `read` in class `DnaSequence`
Parameters:
  `dataOutStream` -
Throws:
  `IOException`

### readDataStream

protected void readDataStream(DataInputStream dataInStream) throws IOException
Read data in binary format

Overrides:
  `readDataStream` in class `DnaSequence`
Parameters:
  `dataOutStream` -
Throws:
  `IOException`

### toString

public String toString()

Overrides:
  `toString` in class `DnaSequence`

### write

public void write(DataOutputStream dataOutStream) throws IOException
Write data in binary format

Overrides:
  `write` in class `DnaSequence`
Parameters:
  `dataOutStream` -
Throws:
  `IOException`