24Allocator<T>::Allocator(
const int dim_,
const int tabSize_): currentTab(
new T[dim_ * tabSize_]), currentId(-1), dim(dim_), tabSize(tabSize_) {}
28Allocator<T>::~Allocator()
30 if(prevTabs.size() == 0 || currentTab != prevTabs.back())
37 for(
unsigned int i = 0; i < prevTabs.size(); ++i)
38 delete [] prevTabs[i];
42void Allocator<T>::shiftTables()
44 prevTabs.push_back(currentTab);
45 currentTab =
new T[dim * tabSize];