Line | |
---|
1 | #ifndef BZ_POINTERSTACK_H |
---|
2 | #define BZ_POINTERSTACK_H |
---|
3 | |
---|
4 | #include <blitz/blitz.h> |
---|
5 | |
---|
6 | BZ_NAMESPACE(blitz) |
---|
7 | |
---|
8 | // helper class ConstPointerStack |
---|
9 | template<typename P_numtype, int N_rank> |
---|
10 | class ConstPointerStack { |
---|
11 | public: |
---|
12 | typedef P_numtype T_numtype; |
---|
13 | |
---|
14 | void operator=(const ConstPointerStack<P_numtype,N_rank>& rhs) |
---|
15 | { |
---|
16 | for (int i=0; i<N_rank; ++i) |
---|
17 | stack_[i] = rhs.stack_[i]; |
---|
18 | } |
---|
19 | |
---|
20 | const T_numtype*& operator[](int position) |
---|
21 | { |
---|
22 | return stack_[position]; |
---|
23 | } |
---|
24 | |
---|
25 | private: |
---|
26 | const T_numtype * stack_[N_rank]; |
---|
27 | }; |
---|
28 | |
---|
29 | BZ_NAMESPACE_END |
---|
30 | |
---|
31 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.