casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Attributes | List of all members
casacore::MemoryTraceBlock Class Reference

Class to write begin and end block message. More...

#include <MemoryTrace.h>

Public Member Functions

 MemoryTraceBlock (const std::string &name)
 The constructor writes a block begin message. More...
 
 MemoryTraceBlock (const char *name)
 
 ~MemoryTraceBlock ()
 The constructor writes a block end message. More...
 

Private Attributes

std::string itsName
 

Detailed Description

Class to write begin and end block message.

Synopsis

This class is meant to write memory trace messages indicating the beginning and end of a code block. In this way it is known that the (de)allocate messages between these messages belong to that code block. The constructor writes the begin message, while the destructor writes the end message. Because the destructor is called automatically by the compiler, the user does not have to worry about it; it will also work fine in case of a premature exit from a function.

It is possible to nest blocks as deeply as one likes.

Definition at line 135 of file MemoryTrace.h.

Constructor & Destructor Documentation

casacore::MemoryTraceBlock::MemoryTraceBlock ( const std::string &  name)

The constructor writes a block begin message.

casacore::MemoryTraceBlock::MemoryTraceBlock ( const char *  name)
casacore::MemoryTraceBlock::~MemoryTraceBlock ( )

The constructor writes a block end message.

Member Data Documentation

std::string casacore::MemoryTraceBlock::itsName
private

Definition at line 144 of file MemoryTrace.h.


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