9 #ifndef _fei_Pool_alloc_hpp_
10 #define _fei_Pool_alloc_hpp_
74 template<typename U>
void construct(U* p, const U& val)
98 if (n==0)
return NULL;
106 std::cerr <<
"fei_Pool_alloc ERROR, allocate given bad length ("<<n
107 <<
"), must be " <<n_<<
". throwing exception."<<std::endl;
108 throw std::bad_alloc();
110 return static_cast<T*
>(mem->alloc());
116 if (p == NULL || n == 0)
return;
123 std::cerr <<
"fei_Pool_alloc ERROR, deallocate given bad length ("<<n
124 <<
"), must be " <<n_<<
". aborting."<<std::endl;
bool operator==(const fei_Pool_alloc< T > &, const fei_Pool_alloc< T > &)
bool operator!=(const fei_Pool_alloc< T > &, const fei_Pool_alloc< T > &)
pointer address(reference value) const
void construct(U *p, const U &val)
const_pointer address(const_reference value) const
fei_Pool_alloc< U > other
size_type max_size() const
void deallocate(pointer p, size_type n)
fei_Pool * get_fei_mem_pool(size_t n)
pointer allocate(size_type n, const void *hint=NULL)
std::ptrdiff_t difference_type
const T & const_reference
void construct(pointer p, const T &val)