diff options
author | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-08-03 14:02:36 +0000 |
---|---|---|
committer | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-08-03 14:02:36 +0000 |
commit | 2131c3c61fe7fb7b6d36a27d484739894a6b6d33 (patch) | |
tree | 0b5f71305eb71c19d9d27ecf4b9154db31963f72 /TAO/tao/AnyTypeCode | |
parent | 16e96771850a6dbc7b12e8aef8500851bc3bffb1 (diff) | |
download | ATCD-2131c3c61fe7fb7b6d36a27d484739894a6b6d33.tar.gz |
ChangeLogTag: Tue Aug 3 13:59:58 UTC 2010 Jeff Parsons <j.parsons@vanderbilt.edu>
Diffstat (limited to 'TAO/tao/AnyTypeCode')
-rw-r--r-- | TAO/tao/AnyTypeCode/AnyTypeCode_methods.h | 20 | ||||
-rw-r--r-- | TAO/tao/AnyTypeCode/NVList.cpp | 12 | ||||
-rw-r--r-- | TAO/tao/AnyTypeCode/NVList.h | 9 | ||||
-rw-r--r-- | TAO/tao/AnyTypeCode/NVList.inl | 38 | ||||
-rw-r--r-- | TAO/tao/AnyTypeCode/TypeCode.cpp | 5 | ||||
-rw-r--r-- | TAO/tao/AnyTypeCode/TypeCode.inl | 13 |
6 files changed, 18 insertions, 79 deletions
diff --git a/TAO/tao/AnyTypeCode/AnyTypeCode_methods.h b/TAO/tao/AnyTypeCode/AnyTypeCode_methods.h index d954af4b0ad..32bbd304915 100644 --- a/TAO/tao/AnyTypeCode/AnyTypeCode_methods.h +++ b/TAO/tao/AnyTypeCode/AnyTypeCode_methods.h @@ -29,28 +29,14 @@ #include "tao/Basic_Types.h" #include "tao/orbconf.h" +#include "tao/CORBA_methods.h" TAO_BEGIN_VERSIONED_NAMESPACE_DECL namespace CORBA { - class NamedValue; - typedef NamedValue *NamedValue_ptr; - - class NVList; - typedef NVList *NVList_ptr; - - class TypeCode; - typedef TypeCode *TypeCode_ptr; - - TAO_NAMESPACE_INLINE_FUNCTION void release (NamedValue_ptr); - TAO_NAMESPACE_INLINE_FUNCTION Boolean is_nil (NamedValue_ptr); - - TAO_NAMESPACE_INLINE_FUNCTION void release (NVList_ptr); - TAO_NAMESPACE_INLINE_FUNCTION Boolean is_nil (NVList_ptr ); - - TAO_NAMESPACE_INLINE_FUNCTION Boolean is_nil (TypeCode_ptr); - TAO_NAMESPACE_INLINE_FUNCTION void release (TypeCode_ptr); + template<> + TAO_AnyTypeCode_Export void release (CORBA::TypeCode_ptr); } TAO_END_VERSIONED_NAMESPACE_DECL diff --git a/TAO/tao/AnyTypeCode/NVList.cpp b/TAO/tao/AnyTypeCode/NVList.cpp index 80f127fc5e6..6b0ef8aabc5 100644 --- a/TAO/tao/AnyTypeCode/NVList.cpp +++ b/TAO/tao/AnyTypeCode/NVList.cpp @@ -22,22 +22,18 @@ # include "tao/AnyTypeCode/NVList.inl" #endif /* ! __ACE_INLINE__ */ -ACE_RCSID (AnyTypeCode, - NVList, - "$Id$") - TAO_BEGIN_VERSIONED_NAMESPACE_DECL // Reference counting for DII Request object CORBA::ULong -CORBA::NamedValue::_incr_refcnt (void) +CORBA::NamedValue::_incr_refcount (void) { return ++this->refcount_; } CORBA::ULong -CORBA::NamedValue::_decr_refcnt (void) +CORBA::NamedValue::_decr_refcount (void) { CORBA::ULong const new_count = --this->refcount_; @@ -60,13 +56,13 @@ CORBA::NamedValue::~NamedValue (void) // **************************************************************** CORBA::ULong -CORBA::NVList::_incr_refcnt (void) +CORBA::NVList::_incr_refcount (void) { return ++this->refcount_; } CORBA::ULong -CORBA::NVList::_decr_refcnt (void) +CORBA::NVList::_decr_refcount (void) { CORBA::ULong const new_count = --this->refcount_; diff --git a/TAO/tao/AnyTypeCode/NVList.h b/TAO/tao/AnyTypeCode/NVList.h index 1cf6aef8f21..a3af6fd0688 100644 --- a/TAO/tao/AnyTypeCode/NVList.h +++ b/TAO/tao/AnyTypeCode/NVList.h @@ -11,7 +11,6 @@ */ //============================================================================= - #ifndef TAO_NVLIST_H #define TAO_NVLIST_H @@ -97,8 +96,8 @@ namespace CORBA static NamedValue * _nil (void); // = Reference counting. - ULong _incr_refcnt (void); - ULong _decr_refcnt (void); + ULong _incr_refcount (void); + ULong _decr_refcount (void); // Useful for template programming. typedef NamedValue_ptr _ptr_type; @@ -195,8 +194,8 @@ namespace CORBA static NVList * _nil (void); // = Reference counting. - ULong _incr_refcnt (void); - ULong _decr_refcnt (void); + ULong _incr_refcount (void); + ULong _decr_refcount (void); // = TAO Extensions: diff --git a/TAO/tao/AnyTypeCode/NVList.inl b/TAO/tao/AnyTypeCode/NVList.inl index d0514805ceb..861678e262f 100644 --- a/TAO/tao/AnyTypeCode/NVList.inl +++ b/TAO/tao/AnyTypeCode/NVList.inl @@ -4,21 +4,6 @@ TAO_BEGIN_VERSIONED_NAMESPACE_DECL -ACE_INLINE CORBA::Boolean -CORBA::is_nil (CORBA::NamedValue_ptr nv) -{ - return nv == 0; -} - -ACE_INLINE void -CORBA::release (CORBA::NamedValue_ptr nv) -{ - if (nv) - nv->_decr_refcnt (); -} - -// ************************************************************* - ACE_INLINE CORBA::NamedValue::NamedValue (void) : refcount_ (1), @@ -54,7 +39,7 @@ CORBA::NamedValue::_duplicate (CORBA::NamedValue * x) { if (x != 0) { - x->_incr_refcnt (); + x->_incr_refcount (); } return x; @@ -70,25 +55,6 @@ CORBA::NamedValue::_nil (void) // ************************************************************* ACE_INLINE -CORBA::Boolean -CORBA::is_nil (CORBA::NVList_ptr nvl) -{ - return (CORBA::Boolean) (nvl == 0); -} - -ACE_INLINE -void -CORBA::release (CORBA::NVList_ptr nvl) -{ - if (nvl) - { - nvl->_decr_refcnt (); - } -} - -// **************************************************************** - -ACE_INLINE CORBA::NVList::NVList (void) : max_ (0), refcount_ (1), @@ -112,7 +78,7 @@ CORBA::NVList::_duplicate (CORBA::NVList * x) { if (x != 0) { - x->_incr_refcnt (); + x->_incr_refcount (); } return x; diff --git a/TAO/tao/AnyTypeCode/TypeCode.cpp b/TAO/tao/AnyTypeCode/TypeCode.cpp index b6bf5c65e20..c026a815d07 100644 --- a/TAO/tao/AnyTypeCode/TypeCode.cpp +++ b/TAO/tao/AnyTypeCode/TypeCode.cpp @@ -2,11 +2,6 @@ #include "tao/AnyTypeCode/TypeCode.h" -ACE_RCSID (AnyTypeCode, - TypeCode, - "$Id$") - - #if !defined (__ACE_INLINE__) # include "tao/AnyTypeCode/TypeCode.inl" #endif /* ! __ACE_INLINE__ */ diff --git a/TAO/tao/AnyTypeCode/TypeCode.inl b/TAO/tao/AnyTypeCode/TypeCode.inl index ea1465a83a7..f9cc23f4439 100644 --- a/TAO/tao/AnyTypeCode/TypeCode.inl +++ b/TAO/tao/AnyTypeCode/TypeCode.inl @@ -4,17 +4,14 @@ TAO_BEGIN_VERSIONED_NAMESPACE_DECL -ACE_INLINE CORBA::Boolean -CORBA::is_nil (CORBA::TypeCode_ptr obj) -{ - return obj == 0; -} - +template<> ACE_INLINE void CORBA::release (CORBA::TypeCode_ptr obj) { - if (obj) - obj->tao_release (); + if (obj != 0) + { + obj->tao_release (); + } } // -------------------------------------------------------------- |