|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.jstacs.data.Sequence<T>
de.jstacs.data.Sequence.RecursiveSequence<T>
T - the type of each positionpublic abstract static class Sequence.RecursiveSequence<T>
This is the main class for subsequences, composite sequences, ... . All these
sequences are defined on an existing Sequence. After creating an
Sequence.RecursiveSequence, no SequenceAnnotation of the internally Sequence
is returned by Sequence.getAnnotation(), ...
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class de.jstacs.data.Sequence |
|---|
Sequence.CompositeSequence<T>, Sequence.RecursiveSequence<T>, Sequence.SubSequence<T> |
| Field Summary | |
|---|---|
protected Sequence<T> |
content
The internal sequence. |
| Fields inherited from class de.jstacs.data.Sequence |
|---|
alphabetCon, annotation, rc |
| Constructor Summary | |
|---|---|
Sequence.RecursiveSequence(AlphabetContainer alphabet,
Sequence<T> seq)
Creates a new Sequence.RecursiveSequence on the Sequence
seq with the AlphabetContainer alphabet
using the annotation of the given Sequence. |
|
Sequence.RecursiveSequence(AlphabetContainer alphabet,
SequenceAnnotation[] annotation,
Sequence<T> seq)
Creates a new Sequence.RecursiveSequence on the Sequence
seq with the AlphabetContainer alphabet
and the annotation annotation. |
|
| Method Summary | |
|---|---|
protected void |
addToRepresentation(Object representation,
int pos,
String delim)
This method adds the information of one position to the representation using the specified delimiter |
int |
compareTo(T t1,
T t2)
This method compares to container and is used in Sequence.compareTo(Sequence). |
double |
continuousVal(int pos)
Returns the continuous value at position pos of the
Sequence. |
int |
discreteVal(int pos)
Returns the discrete value at position pos of the
Sequence. |
void |
fillContainer(T container,
int pos)
The method fills the content of a specific position in to the container. |
T |
getEmptyContainer()
The method returns a container that can be used for accessing the symbols for each position. |
protected Object |
getEmptyRepresentation()
Returns an empty representation which is used to create the String representation of this instance in the method Sequence.toString(String, int, int). |
protected abstract int |
getIndex(int pos)
Returns the index in the internal sequence. |
protected String |
getStringRepresentation(Object representation)
This method creates a String representation from the given representation. |
protected int |
hashCodeForPos(int pos)
This method is used in Sequence.hashCode() and the hash code for one specific position. |
boolean |
isMultiDimensional()
The method returns true if the sequence is multidimensional, otherwise . |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected Sequence<T> content
| Constructor Detail |
|---|
public Sequence.RecursiveSequence(AlphabetContainer alphabet,
SequenceAnnotation[] annotation,
Sequence<T> seq)
Sequence.RecursiveSequence on the Sequence
seq with the AlphabetContainer alphabet
and the annotation annotation.
alphabet - the AlphabetContainerannotation - the annotation of the Sequence.RecursiveSequenceseq - the sequenceSequence.Sequence(AlphabetContainer, SequenceAnnotation[])
public Sequence.RecursiveSequence(AlphabetContainer alphabet,
Sequence<T> seq)
Sequence.RecursiveSequence on the Sequence
seq with the AlphabetContainer alphabet
using the annotation of the given Sequence.
alphabet - the AlphabetContainerseq - the sequence| Method Detail |
|---|
public double continuousVal(int pos)
Sequencepos of the
Sequence.
continuousVal in class Sequence<T>pos - the position of the Sequence
pos of the
Sequencepublic int discreteVal(int pos)
Sequencepos of the
Sequence.
discreteVal in class Sequence<T>pos - the position of the Sequence
pos of the
Sequenceprotected abstract int getIndex(int pos)
pos - the index in the external sequence
public boolean isMultiDimensional()
Sequencetrue if the sequence is multidimensional, otherwise .
- Specified by:
isMultiDimensional in class Sequence<T>
- Returns:
true if the sequence is multidimensional, otherwise
public T getEmptyContainer()
Sequence
getEmptyContainer in class Sequence<T>Sequence.fillContainer(Object, int),
Sequence.isMultiDimensional()
public void fillContainer(T container,
int pos)
Sequence
fillContainer in class Sequence<T>container - the container which is used for filling the content.pos - the positionSequence.getEmptyContainer(),
Sequence.isMultiDimensional()
public int compareTo(T t1,
T t2)
SequenceSequence.compareTo(Sequence).
compareTo in class Sequence<T>t1 - the first containert2 - the second container
Sequence.getEmptyContainer(),
Sequence.fillContainer(Object, int),
Comparable.compareTo(java.lang.Object)protected Object getEmptyRepresentation()
SequenceString representation of this instance in the method Sequence.toString(String, int, int).
getEmptyRepresentation in class Sequence<T>String representationSequence.toString(String, int, int)
protected void addToRepresentation(Object representation,
int pos,
String delim)
Sequence
addToRepresentation in class Sequence<T>representation - the representationpos - the positiondelim - the delimiter separating the information for different positionsSequence.getEmptyRepresentation(),
Sequence.toString(String, int, int)protected String getStringRepresentation(Object representation)
Sequence
getStringRepresentation in class Sequence<T>representation - the representation instance (which should be created by Sequence.getEmptyContainer() and filled by Sequence.addToRepresentation(Object, int, String))
Sequence.getEmptyRepresentation(),
Sequence.addToRepresentation(Object, int, String),
Sequence.toString(String, int, int)protected int hashCodeForPos(int pos)
SequenceSequence.hashCode() and the hash code for one specific position.
hashCodeForPos in class Sequence<T>pos - the position
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||