- Type Parameters:
S- the sequence typeC- each element of theAlignedSequenceis aCompoundof type C
- All Superinterfaces:
Accessioned,AlignedSequence<S,,C> Iterable<C>,Sequence<C>
public interface MutableAlignedSequence<S extends Sequence<C>,C extends Compound>
extends AlignedSequence<S,C>
Defines a mutable (editable) data structure for an
AlignedSequence.- Author:
- Mark Chapman, Paolo Pavan
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.biojava.nbio.core.alignment.template.AlignedSequence
AlignedSequence.Step -
Method Summary
Modifier and TypeMethodDescriptionvoidsetLocationInAlignment(Location location) Sets the position of theAlignedSequenceto the givenLocation(start, gaps, end).voidshiftAtAlignmentLocation(Location location, int shift) Slides a part of theAlignedSequence.voidshiftAtSequenceLocation(Location location, int shift) Slides a part of theAlignedSequence.Methods inherited from interface org.biojava.nbio.core.sequence.template.Accessioned
getAccessionMethods inherited from interface org.biojava.nbio.core.alignment.template.AlignedSequence
clearCache, getAlignmentFromSequence, getAlignmentIndexAt, getCoverage, getEnd, getLocationInAlignment, getNumGapPositions, getNumGaps, getOriginalSequence, getOverlapCount, getSequenceFromAlignment, getSequenceIndexAt, getStart, isCircular, isGapMethods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface org.biojava.nbio.core.sequence.template.Sequence
countCompounds, getAsList, getCompoundAt, getCompoundSet, getIndexOf, getInverse, getLastIndexOf, getLength, getSequenceAsString, getSubSequence
-
Method Details
-
setLocationInAlignment
Sets the position of theAlignedSequenceto the givenLocation(start, gaps, end).- Parameters:
location- new location for this sequence- Throws:
IllegalArgumentException- if location is invalid
-
shiftAtAlignmentLocation
Slides a part of theAlignedSequence.- Parameters:
location- portion of sequence moved in alignment coordinatesshift- amount the alignment index changes for each contained element- Throws:
IllegalArgumentException- if location is invalid or the shift causes a collision with stationary elements
-
shiftAtSequenceLocation
Slides a part of theAlignedSequence.- Parameters:
location- portion of sequence moved in sequence coordinatesshift- amount the alignment index changes for each contained element- Throws:
IllegalArgumentException- if location is invalid or the shift causes a collision with stationary elements
-