41 #ifndef vtkXMLOffsetsManager_DoNotInclude
42 #error "do not include unless you know what you are doing"
45 #ifndef vtkXMLOffsetsManager_h
46 #define vtkXMLOffsetsManager_h
59 this->LastMTime =
static_cast<unsigned long>(-1);
63 assert( numTimeStep > 0);
64 this->Positions.resize(numTimeStep);
65 this->RangeMinPositions.resize(numTimeStep);
66 this->RangeMaxPositions.resize(numTimeStep);
67 this->OffsetValues.resize(numTimeStep);
71 assert( t < this->Positions.size());
72 return this->Positions[t];
76 assert( t < this->RangeMinPositions.size());
77 return this->RangeMinPositions[t];
81 assert( t < this->RangeMaxPositions.size());
82 return this->RangeMaxPositions[t];
86 assert( t < this->OffsetValues.size());
87 return this->OffsetValues[t];
91 return this->LastMTime;
94 unsigned long LastMTime;
100 std::vector<vtkTypeInt64> Positions;
101 std::vector<vtkTypeInt64> RangeMinPositions;
102 std::vector<vtkTypeInt64> RangeMaxPositions;
104 std::vector<vtkTypeInt64> OffsetValues;
119 assert( index < this->Internals.size());
135 return static_cast<unsigned int>(this->Internals.size());
139 assert(numElements >= 0);
140 this->Internals.resize(numElements);
144 assert(numElements > 0);
145 assert(numTimeSteps > 0);
146 this->Internals.resize(numElements);
147 for(
int i=0; i<numElements; i++)
149 this->Internals[i].Allocate(numTimeSteps);
153 std::vector<OffsetsManager> Internals;
162 assert( index < this->Internals.size());
163 return this->Internals[
index];
167 assert(numPieces > 0);
169 this->Internals.resize(0);
170 this->Internals.resize(numPieces);
172 void Allocate(
int numPieces,
int numElements,
int numTimeSteps)
174 assert(numPieces > 0);
175 assert(numElements > 0);
176 assert(numTimeSteps > 0);
179 this->Internals.resize(0);
180 this->Internals.resize(numPieces);
181 for(
int i=0; i<numPieces; i++)
183 this->Internals[i].Allocate(numElements, numTimeSteps);
187 std::vector<OffsetsManagerGroup> Internals;
OffsetsManagerGroup & GetPiece(unsigned int index)
void Allocate(int numTimeStep)
void Allocate(int numElements)
void Allocate(int numPieces)
Helper class due to PIMPL excess.
OffsetsManager & GetPiece(unsigned int index)
vtkTypeInt64 & GetRangeMaxPosition(unsigned int t)
unsigned int GetNumberOfElements()
vtkTypeInt64 & GetRangeMinPosition(unsigned int t)
vtkTypeInt64 & GetPosition(unsigned int t)
vtkTypeInt64 & GetOffsetValue(unsigned int t)
void Allocate(int numElements, int numTimeSteps)
unsigned long & GetLastMTime()
void Allocate(int numPieces, int numElements, int numTimeSteps)
OffsetsManager & GetElement(unsigned int index)