46 #define G4Allocator_h 1
130 mem_alloc =
static_cast<Type*
>(::operator
new(n*
sizeof(Type)));
140 ::operator
delete((
void*)p);
153 return 2147483647/
sizeof(Type);
181 template <
class Type>
185 tname =
typeid(Type).
name();
192 template <
class Type>
201 template <
class Type>
204 return static_cast<Type*
>(mem.Alloc());
211 template <
class Type>
222 template <
class Type>
235 template <
class Type>
245 template <
class Type>
248 return mem.GetNoPages();
255 template <
class Type>
258 return mem.GetPageSize();
265 template <
class Type>
269 mem.GrowPageSize(sz);
276 template <
class Type>
286 template <
class T1,
class T2>
296 template <
class T1,
class T2>
bool operator!=(const BasicVector3D< float > &a, const BasicVector3D< float > &b)
size_t GetAllocatedSize() const
virtual void IncreasePageSize(unsigned int sz)=0
ptrdiff_t difference_type
virtual size_t GetAllocatedSize() const =0
size_type max_size() const
void FreeSingle(Type *anElement)
void construct(pointer p, const Type &val)
void deallocate(pointer p, size_type n)
bool operator==(const BasicVector3D< float > &a, const BasicVector3D< float > &b)
virtual void ResetStorage()=0
virtual int GetNoPages() const =0
virtual size_t GetPageSize() const =0
G4Allocator(const G4Allocator< U > &right)
const char * GetPoolType() const
const Type * const_pointer
const_pointer address(const_reference r) const
size_t GetPageSize() const
pointer address(reference r) const
virtual const char * GetPoolType() const =0
pointer allocate(size_type n, void *=0)
const Type & const_reference
virtual ~G4AllocatorBase()
void IncreasePageSize(unsigned int sz)