7 #ifndef _HALDNAITERATOR_H
8 #define _HALDNAITERATOR_H
23 virtual char getChar()
const = 0;
28 virtual void setChar(
char c) = 0;
31 virtual void toLeft()
const = 0;
34 virtual void toRight()
const = 0;
39 virtual void jumpTo(hal_size_t index)
const = 0;
66 virtual bool equals(DNAIteratorConstPtr& other)
const = 0;
69 virtual bool leftOf(DNAIteratorConstPtr& other)
const = 0;
73 friend class counted_ptr<DNAIterator>;
74 friend class counted_ptr<const DNAIterator>;
75 virtual ~DNAIterator() = 0;
78 inline DNAIterator::~DNAIterator() {}
83 #include "halGenome.h"
85 inline std::ostream& operator<<(std::ostream& os,
86 const DNAIterator* dna)
88 const Genome* genome = dna->getGenome();
90 os <<
"Genome=" << genome->getName();
91 os <<
" Seq=" << dna->getSequence()->getName();
92 os <<
" idx=" << dna->getArrayIndex();
94 if (dna->getArrayIndex() >= 0 &&
95 dna->getArrayIndex() < (hal_index_t)genome->getSequenceLength())
97 os <<
" val=" << dna->getChar();
Definition: halGenome.h:24
Definition: halDNAIterator.h:17
virtual void jumpTo(hal_size_t index) const =0
virtual const Genome * getGenome() const =0
virtual void toRight() const =0
virtual void toLeft() const =0
virtual bool leftOf(DNAIteratorConstPtr &other) const =0
virtual hal_index_t getArrayIndex() const =0
virtual const Sequence * getSequence() const =0
virtual void toReverse() const =0
virtual bool getReversed() const =0
virtual void setChar(char c)=0
virtual bool equals(DNAIteratorConstPtr &other) const =0
virtual char getChar() const =0
virtual void setReversed(bool reversed) const =0
Definition: halSequence.h:20