ACE_Dynamic(3)

ACE_Dynamic3

Checks to see if an object was dynamically allocated.

Usage

#include <ace/Dynamic.h>
class ACE_Dynamic
{
  public:
    ACE_Dynamic (void);
    ~ACE_Dynamic (void);
    void set (void);
    int is_dynamic (void);
    void reset (void);
    static ACE_Dynamic *instance (void);
  private:
    int is_dynamic_;
};

Overview

This class holds the pointer in a thread-safe manner between the call to operator new and the call to the constructor.

Initialization and termination method.

ACE_Dynamic (void);

Constructor.

~ACE_Dynamic (void);

Destructor.

void set (void);

Sets a flag that indicates that the object was dynamically created. This method is usually called in operator new and then checked and reset in the constructor.

int is_dynamic (void);

1 if we were allocated dynamically, else 0.

void reset (void);

Resets state flag.

static ACE_Dynamic *instance (void);

Library

ace

Author

Doug Schmidt and Irfan Pyrarli.

From libace-doc 5.0.7-4 in Debian 2.2 (Potato). Parsed by carta from the page's man source.