11 #ifndef __GT_DASubArray__
12 #define __GT_DASubArray__
40 , myStart(src.myStart)
47 const char *
className()
const override {
return "GT_DASubArray"; }
59 {
return myData->itemSize(this->getIndirect(offset)); }
63 for (
GT_Size off = myStart; off < myStart; ++off)
64 sum += myData->itemSize(off);
73 {
return myStart +
offset; }
GT_DASubArray(const GT_DataArrayHandle &data, GT_Offset start, GT_Size size)
Useful constructor.
void init(const GT_DataArrayHandle &data, GT_Offset start, GT_Size size)
Initialize with given data.
GT_Size itemSize(GT_Offset offset) const override
GT_DASubArray(const GT_DASubArray &src)
Copy constructor.
GT_DASubArray()
Default constructor.
GT_Size getTotalArrayEntries() const override
A slice of a different data array.
Base class for a data array which references another data array.
#define GT_IMPL_INHERIT_ARRAY(MAP_INDEX, SIZE)
void init(const GT_DataArrayHandle &data)
const char * className() const override