CookMem 1.4.0
A C++ memory context / allocator
Loading...
Searching...
No Matches
cookmem::NoActionMemLogger Class Reference

#include <logger.h>

Public Member Functions

 NoActionMemLogger ()
 
void logGetSegment (void *, std::size_t)
 
void logFreeSegment (void *, std::size_t)
 
void logTrimEmptySegments ()
 
void logAllocation (void *, std::size_t, MemAllocType_et)
 
void logReallocation (void *, std::size_t, std::size_t)
 
void logDeallocation (void *, std::size_t)
 
void logError (void *, MemError_et error, const char *file=__FILE__, int line=__LINE__)
 

Detailed Description

A very simple MemLogger that does mostly nothing.

This class implements the interface of MemLogger without explicitly inheriting from it. This is to avoid the overhead of virtual function calls and allows inlining of the functions.

Constructor & Destructor Documentation

◆ NoActionMemLogger()

cookmem::NoActionMemLogger::NoActionMemLogger ( )
inline

Constructor.

Member Function Documentation

◆ logAllocation()

void cookmem::NoActionMemLogger::logAllocation ( void *  ,
std::size_t  ,
MemAllocType_et   
)
inline

Does nothing. See MemLogger::logAllocation().

◆ logDeallocation()

void cookmem::NoActionMemLogger::logDeallocation ( void *  ,
std::size_t   
)
inline

Does nothing. See MemLogger::logDeallocation().

◆ logError()

void cookmem::NoActionMemLogger::logError ( void *  ,
MemError_et  error,
const char *  file = __FILE__,
int  line = __LINE__ 
)
inline

Report a memory error by throwing an exception.

Parameters
errorthe type of the error encountered.
filethe source file where the error was detected.
linethe line number where the error was detected.
Exceptions
Exceptionalways.

◆ logFreeSegment()

void cookmem::NoActionMemLogger::logFreeSegment ( void *  ,
std::size_t   
)
inline

Does nothing. See MemLogger::logFreeSegment().

◆ logGetSegment()

void cookmem::NoActionMemLogger::logGetSegment ( void *  ,
std::size_t   
)
inline

Does nothing. See MemLogger::logGetSegment().

◆ logReallocation()

void cookmem::NoActionMemLogger::logReallocation ( void *  ,
std::size_t  ,
std::size_t   
)
inline

Does nothing. See MemLogger::logReallocation().

◆ logTrimEmptySegments()

void cookmem::NoActionMemLogger::logTrimEmptySegments ( )
inline

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