2022-09-09 19:41:43 +02:00
|
|
|
|
|
|
|
#ifndef __cxz_darray_h__
|
|
|
|
#define __cxz_darray_h__
|
|
|
|
|
2022-09-15 16:45:45 +02:00
|
|
|
#include "darray_base.h"
|
2022-09-09 19:41:43 +02:00
|
|
|
|
|
|
|
namespace CNORXZ
|
|
|
|
{
|
|
|
|
|
|
|
|
template <typename T>
|
|
|
|
class DArray : public MDArrayBase<T>
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
typedef DArrayBase<T> AB;
|
|
|
|
typedef typename AB::const_iterator const_iterator;
|
|
|
|
|
|
|
|
using DArrayBase<T>::operator[];
|
|
|
|
using MDArrayBase<T>::operator[];
|
|
|
|
|
|
|
|
DEFAULT_MEMBERS(DArray);
|
|
|
|
DArray(const RangePtr& range);
|
2022-09-15 16:45:45 +02:00
|
|
|
DArray(const RangePtr& range, const Vector<T>& vec);
|
|
|
|
DArray(const RangePtr& range, Vector<T>&& vec);
|
2022-09-09 19:41:43 +02:00
|
|
|
|
2022-11-22 19:11:41 +01:00
|
|
|
virtual SizeT pmax() const override;
|
2022-09-09 19:41:43 +02:00
|
|
|
virtual const T* data() const override;
|
|
|
|
virtual T* data() override;
|
|
|
|
virtual const_iterator cbegin() const override;
|
|
|
|
virtual const_iterator cend() const override;
|
|
|
|
virtual bool isView() const override;
|
|
|
|
|
2022-11-22 19:11:41 +01:00
|
|
|
private:
|
|
|
|
Vector<T> mCont;
|
2022-09-09 19:41:43 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|