HTGS  v2.0
The Hybrid Task Graph Scheduler
htgs::AnyMemoryAllocator Class Reference

Create a base class for a memory allocator that removes the template and defines common functionality for any memory allocator. More...

#include <htgs/core/memory/AnyMemoryAllocator.hpp>

Inheritance diagram for htgs::AnyMemoryAllocator:
Inheritance graph
Collaboration diagram for htgs::AnyMemoryAllocator:
Collaboration graph

Public Member Functions

 AnyMemoryAllocator (size_t size)
 Creates a memory allocator. More...
 
virtual ~AnyMemoryAllocator ()
 Destructor.
 
size_t size () const
 Gets the size. More...
 

Private Attributes

size_t _size
 The size of the memory (in elements)
 

Detailed Description

Create a base class for a memory allocator that removes the template and defines common functionality for any memory allocator.

Constructor & Destructor Documentation

◆ AnyMemoryAllocator()

htgs::AnyMemoryAllocator::AnyMemoryAllocator ( size_t  size)
inline

Creates a memory allocator.

Parameters
sizethe number of elements to allocate

Member Function Documentation

◆ size()

size_t htgs::AnyMemoryAllocator::size ( ) const
inline

Gets the size.

Returns
the size

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