Generated on Sat Jan 12 2019 20:58:51 for Gecode by doxygen 1.8.13
Gecode::Support::Allocator Class Reference

Default memory allocator. More...

#include <allocator.hpp>

Public Member Functions

 Allocator (void)
 Default constructor. More...
 
void * alloc (size_t n)
 Allocate memory block of size n. More...
 
void * realloc (void *p, size_t n)
 Return address of reallocated memory block p of size n. More...
 
void free (void *p)
 Free memory block p. More...
 
void * memcpy (void *d, const void *s, size_t n)
 Copy n bytes from source s directly to d and returns d. More...
 

Detailed Description

Default memory allocator.

Acts as a wrapper around memory allocation functionality.

Can be disabled by giving a "-disable-allocator" option to configure and the be re-implemented before including any other Gecode header.

Definition at line 60 of file allocator.hpp.

Constructor & Destructor Documentation

◆ Allocator()

Gecode::Support::Allocator::Allocator ( void  )
inline

Default constructor.

Definition at line 76 of file allocator.hpp.

Member Function Documentation

◆ alloc()

void * Gecode::Support::Allocator::alloc ( size_t  n)
inline

Allocate memory block of size n.

Definition at line 79 of file allocator.hpp.

◆ realloc()

void * Gecode::Support::Allocator::realloc ( void *  p,
size_t  n 
)
inline

Return address of reallocated memory block p of size n.

Definition at line 83 of file allocator.hpp.

◆ free()

void Gecode::Support::Allocator::free ( void *  p)
inline

Free memory block p.

Definition at line 87 of file allocator.hpp.

◆ memcpy()

void * Gecode::Support::Allocator::memcpy ( void *  d,
const void *  s,
size_t  n 
)
inline

Copy n bytes from source s directly to d and returns d.

Definition at line 91 of file allocator.hpp.


The documentation for this class was generated from the following file: