edu.unc.csbio.data
Class SequenceBuffer

java.lang.Object
  extended by edu.unc.csbio.data.SequenceBuffer
Direct Known Subclasses:
ExtendedSequenceBuffer

public class SequenceBuffer
extends java.lang.Object

The class for sequence information, including sequence string and the offset

Version:
0.1
Author:
Shunping Huang , Jack Wang

Field Summary
private  int length
           
private  int offset
          The the position difference between the start position of sequence and the start position of the reference gene, of the object SequenceBuffer
private  java.lang.String raw
          The sequence of the object SequenceBuffer
 
Constructor Summary
SequenceBuffer(java.lang.String _raw, int _offset)
          A constructor for object SequenceBuffer
 
Method Summary
 java.lang.String get(int start, int end)
          Get the sequence for the region [start, end]
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

raw

private java.lang.String raw
The sequence of the object SequenceBuffer


offset

private int offset
The the position difference between the start position of sequence and the start position of the reference gene, of the object SequenceBuffer


length

private int length
Constructor Detail

SequenceBuffer

public SequenceBuffer(java.lang.String _raw,
                      int _offset)
A constructor for object SequenceBuffer

Parameters:
_raw - the sequence
_offset - the position difference between the start position of sequence and the start position of the reference gene
Method Detail

get

public java.lang.String get(int start,
                            int end)
Get the sequence for the region [start, end]

Parameters:
start - the start position of the region in reference coordinate.
end - the end position of the region in reference coordinate.
Returns:
the sequence in the specified region