add method

void add(
  1. NucleotideSequence seq, {
  2. bool useDirection = true,
})

(en) Combines this NucleotideSequence with another NucleotideSequence.

(ja) このNucleotideSequenceに別のNucleotideSequenceを結合します。

  • seq : The other sequence.
  • useDirection : If true, The direction is taken into account, if it's the opposite direction, it flips the other array and then joins it.

Implementation

void add(NucleotideSequence seq, {bool useDirection = true}) {
  if (useDirection) {
    if ((direction == seq.direction)) {
      sequence.addAll(seq.sequence);
    } else {
      sequence.addAll(seq.sequence.reversed);
    }
  } else {
    sequence.addAll(seq.sequence);
  }
}