Thomas Tsou | 20eb6d6 | 2013-11-09 14:30:41 -0500 | [diff] [blame] | 1 | #ifndef _SIGNALVECTOR_H_ |
| 2 | #define _SIGNALVECTOR_H_ |
| 3 | |
| 4 | #include <Vector.h> |
| 5 | #include <Complex.h> |
| 6 | |
| 7 | /** Vector symmetry */ |
| 8 | enum Symmetry { |
| 9 | NONE = 0, |
| 10 | ABSSYM = 1 |
| 11 | }; |
| 12 | |
| 13 | class signalVector: public Vector<complex> { |
| 14 | public: |
| 15 | /** Default constructor */ |
| 16 | signalVector(size_t size = 0); |
| 17 | |
| 18 | /** Construct with head room */ |
| 19 | signalVector(size_t size, size_t start); |
| 20 | |
| 21 | /** Construct from existing buffer data (buffer not managed) */ |
| 22 | signalVector(complex *data, size_t start, size_t span); |
| 23 | |
| 24 | /** Construct by from existing vector */ |
| 25 | signalVector(const signalVector &vector); |
| 26 | |
| 27 | /** Construct by from existing vector and append head-tail room */ |
| 28 | signalVector(const signalVector &vector, size_t start, size_t tail = 0); |
| 29 | |
| 30 | /** Override base assignment operator to include start offsets */ |
| 31 | void operator=(const signalVector& vector); |
| 32 | |
| 33 | /** Return head room */ |
| 34 | size_t getStart() const; |
| 35 | |
| 36 | Symmetry getSymmetry() const; |
| 37 | void setSymmetry(Symmetry symmetry); |
| 38 | |
| 39 | bool isReal() const; |
| 40 | void isReal(bool real); |
| 41 | |
| 42 | bool isAligned() const; |
| 43 | void setAligned(bool aligned); |
| 44 | |
| 45 | private: |
| 46 | Symmetry symmetry; |
| 47 | bool real; |
| 48 | bool aligned; |
| 49 | }; |
| 50 | |
| 51 | #endif /* _SIGNALVECTOR_H_ */ |