Loading...
Searching...
No Matches
casacore::MemoryTraceBlock Class Reference
casa package (libcasa_casa) » OS_module

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.
| MemoryTraceBlock (const char *name)
| ~MemoryTraceBlock ()
| The constructor writes a block end message.

## 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 133 of file MemoryTrace.h.

## Constructor & Destructor Documentation

## MemoryTraceBlock() [1/2]

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

The constructor writes a block begin message.

References casacore::name().

## MemoryTraceBlock() [2/2]

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

References casacore::name().

## ~MemoryTraceBlock()

casacore::MemoryTraceBlock::~MemoryTraceBlock | ( |  | ) |

The constructor writes a block end message.

## Member Data Documentation

## itsName

std::string casacore::MemoryTraceBlock::itsName

private

Definition at line 142 of file MemoryTrace.h.

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

- casa/OS/MemoryTrace.h