org.utgenome.format.fasta
Class CompactACGT

java.lang.Object
  extended by org.utgenome.format.fasta.CompactACGT
All Implemented Interfaces:
GenomeSequence

public class CompactACGT
extends Object
implements GenomeSequence

Compact array for ACGT (and N) sequences

Author:
leo

Method Summary
 char charAt(int index)
           
static CompactACGT createFromString(String seq)
           
 OverlappingKmerIterator getKmerIterator(int K)
           
 int length()
           
 CompactACGT reverseComplement()
           
 CompactACGT subSequence(int start, int length)
          return a subsequence of this ACGT string.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

subSequence

public CompactACGT subSequence(int start,
                               int length)
                        throws UTGBException
return a subsequence of this ACGT string. The returned CompactACGT holds the references to the sequence byte arrays, and no buffer copy will be performed.

Parameters:
start -
length -
Returns:
Throws:
UTGBException

reverseComplement

public CompactACGT reverseComplement()
                              throws UTGBException
Throws:
UTGBException

getKmerIterator

public OverlappingKmerIterator getKmerIterator(int K)

createFromString

public static CompactACGT createFromString(String seq)
                                    throws IOException,
                                           UTGBException
Throws:
IOException
UTGBException

length

public int length()
Specified by:
length in interface GenomeSequence

charAt

public char charAt(int index)
Specified by:
charAt in interface GenomeSequence
Parameters:
index - index on the genome sequence (0-origin)
Returns:

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2007-2012 utgenome.org. All Rights Reserved.