summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ace/Managed_Object.h12
-rw-r--r--ace/Managed_Object.i8
2 files changed, 12 insertions, 8 deletions
diff --git a/ace/Managed_Object.h b/ace/Managed_Object.h
index 449da574bd7..56b34c838f7 100644
--- a/ace/Managed_Object.h
+++ b/ace/Managed_Object.h
@@ -20,21 +20,25 @@
#include "ace/OS.h"
template <class TYPE>
-class ACE_Managed_Cleanup : public ACE_Cleanup
+class ACE_Cleanup_Adapter : public ACE_Cleanup
// = TITLE
// Adapter for ACE_Cleanup objects that allows them to be readily
// managed by the ACE_Object_Manager.
//
// = DESCRIPTION
// This template class wraps adapts an object of any type to be
- // an ACE_Cleanup object. It can then be destroyed type-safely
- // by the ACE_Object_Manager.
+ // an ACE_Cleanup object. The object can then be destroyed
+ // type-safely by the ACE_Object_Manager.
{
public:
- ACE_Managed_Cleanup (void);
+ ACE_Cleanup_Adapter (void);
+ // Default constructor.
+
TYPE &object (void);
+ // Accessor for contained object.
private:
TYPE object_;
+ // Contained object.
};
template <class TYPE>
diff --git a/ace/Managed_Object.i b/ace/Managed_Object.i
index 9c38a7542c5..c87fe9ff691 100644
--- a/ace/Managed_Object.i
+++ b/ace/Managed_Object.i
@@ -5,14 +5,14 @@
// have a default constructor. Let the compiler figure it out . . .
template <class TYPE>
ACE_INLINE
-ACE_Managed_Cleanup<TYPE>::ACE_Managed_Cleanup (void)
+ACE_Cleanup_Adapter<TYPE>::ACE_Cleanup_Adapter (void)
{
}
template <class TYPE>
ACE_INLINE
TYPE &
-ACE_Managed_Cleanup<TYPE>::object (void)
+ACE_Cleanup_Adapter<TYPE>::object (void)
{
return this->object_;
}
@@ -30,7 +30,7 @@ ACE_Managed_Object<TYPE>::get_preallocated_object
// Cast the return type of the the object pointer based
// on the type of the function template parameter.
- return &((ACE_Managed_Cleanup<TYPE> *)
+ return &((ACE_Cleanup_Adapter<TYPE> *)
ACE_Object_Manager::preallocated_object[id])->object ();
}
@@ -47,6 +47,6 @@ ACE_Managed_Object<TYPE>::get_preallocated_array
// Cast the return type of the the object pointer based
// on the type of the function template parameter.
- return &((ACE_Managed_Cleanup<TYPE> *)
+ return &((ACE_Cleanup_Adapter<TYPE> *)
ACE_Object_Manager::preallocated_array[id])->object ();
}