@ Override public < C extends Compound > Sequence < C > getSubSequence ( Sequence < C > sequence ) { if ( isCircular ( ) ) { List < Sequence < C >> sequences = new ArrayList < Sequence < C > > ( ) ; for ( Location l : this ) { sequences . add ( l . getSubSequence ( sequence ) ) ; } return new JoiningSequenceReader < C > ( sequence . getCompoundSet ( ) , sequences ) ; } return reverseSequence ( sequence . getSubSequence ( getStart ( ) . getPosition ( ) , getEnd ( ) . getPosition ( ) ) ) ; }
If circular this will return the sequence represented by the sub locations joined . If not circular then we get the Sequence for the outer - bounds defined by this location .