23 template<
class T,
int NumExtAlloc = DEFAULTVEC_ALLOC >
47 void Push(
const T
object);
68 operator T*()
const {
return this->
fStore; }
73 template<
class T,
int NumExtAlloc >
79 template<
class T,
int NumExtAlloc >
86 template<
class T,
int NumExtAlloc >
91 PZError <<
"TPZStack popping beyond the stack object" << std::endl;
99 template <
class T,
int NumExtAlloc >
102 PZError <<
"TPZStack peek beyond the stack object" << std::endl;
TPZStack(int nel, const T Object)
Implements a vector class which allows to use external storage provided by the user. Utility.
T & operator[](const int64_t index) const
Access operator, will perform bounds checking unless the variable NODEBUG is defined.
void Expand(const int64_t newsize)
Expands the allocated storage to fit the newsize parameter.
virtual void Resize(const int64_t newsize, const T &object)
Resizes the vector object.
TPZStack()
Create the stack object, indicates the stack increments.
void Push(const T object)
Pushes a copy of the object on the stack.
Free store vector implementation.
T * fStore
Allocated storage for the vector object.
T Pop()
Retrieve an object from the stack.
int64_t fNElements
Number of elements of the vector object.
This class implements a stack object. Utility.
int64_t NElements() const
Returns the number of elements of the vector.
void push_back(const T object)
#define PZError
Defines the output device to error messages and the DebugStop() function.