summaryrefslogtreecommitdiff
path: root/TAO/tao/ORB.i
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tao/ORB.i')
-rw-r--r--TAO/tao/ORB.i177
1 files changed, 12 insertions, 165 deletions
diff --git a/TAO/tao/ORB.i b/TAO/tao/ORB.i
index 2a219388c0a..16a9d6be7e6 100644
--- a/TAO/tao/ORB.i
+++ b/TAO/tao/ORB.i
@@ -10,7 +10,10 @@
ACE_INLINE CORBA::ULong
CORBA::ORB::_incr_refcnt (void)
{
- ACE_GUARD_RETURN (TAO_SYNCH_MUTEX, guard, lock_, 0);
+ ACE_GUARD_RETURN (TAO_SYNCH_MUTEX,
+ guard,
+ lock_,
+ 0);
return ++this->refcount_;
}
@@ -20,8 +23,11 @@ CORBA::ORB::_decr_refcnt (void)
{
ACE_GUARD_RETURN (TAO_SYNCH_MUTEX, mon, this->lock_, 0);
this->refcount_--;
+
if (this->refcount_ != 0)
- return this->refcount_;
+ {
+ return this->refcount_;
+ }
}
delete this;
@@ -32,7 +38,10 @@ ACE_INLINE CORBA::ORB_ptr
CORBA::ORB::_duplicate (CORBA::ORB_ptr obj)
{
if (obj)
- obj->_incr_refcnt ();
+ {
+ obj->_incr_refcnt ();
+ }
+
return obj;
}
@@ -79,165 +88,3 @@ CORBA::release (CORBA::ORB_ptr obj)
obj->_decr_refcnt ();
}
-// *************************************************************
-// Inline operations for class CORBA::ORB_var
-// *************************************************************
-
-ACE_INLINE
-CORBA::ORB_var::ORB_var (void) // default constructor
- : ptr_ (CORBA::ORB::_nil ())
-{
-}
-
-ACE_INLINE
-CORBA::ORB_var::ORB_var (CORBA::ORB_ptr p)
- : ptr_ (p)
-{
-}
-
-ACE_INLINE CORBA::ORB_ptr
-CORBA::ORB_var::ptr (void) const
-{
- return this->ptr_;
-}
-
-ACE_INLINE
-CORBA::ORB_var::ORB_var (const CORBA::ORB_var &p) // copy constructor
- : ptr_ (CORBA::ORB::_duplicate (p.ptr ()))
-{
-}
-
-ACE_INLINE
-CORBA::ORB_var::~ORB_var (void) // destructor
-{
- CORBA::release (this->ptr_);
-}
-
-ACE_INLINE CORBA::ORB_var &
-CORBA::ORB_var::operator= (CORBA::ORB_ptr p)
-{
- CORBA::release (this->ptr_);
- this->ptr_ = p;
- return *this;
-}
-
-ACE_INLINE CORBA::ORB_var &
-CORBA::ORB_var::operator= (const CORBA::ORB_var &p)
-{
- if (this != &p)
- {
- CORBA::release (this->ptr_);
- this->ptr_ = CORBA::ORB::_duplicate (p.ptr ());
- }
- return *this;
-}
-
-ACE_INLINE
-CORBA::ORB_var::operator const CORBA::ORB_ptr &() const // cast
-{
- return this->ptr_;
-}
-
-ACE_INLINE
-CORBA::ORB_var::operator CORBA::ORB_ptr &() // cast
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr
-CORBA::ORB_var::operator-> (void) const
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr
-CORBA::ORB_var::in (void) const
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr &
-CORBA::ORB_var::inout (void)
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr &
-CORBA::ORB_var::out (void)
-{
- CORBA::release (this->ptr_);
- this->ptr_ = CORBA::ORB::_nil ();
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr
-CORBA::ORB_var::_retn (void)
-{
- // yield ownership of managed obj reference
- CORBA::ORB_ptr val = this->ptr_;
- this->ptr_ = CORBA::ORB::_nil ();
- return val;
-}
-
-// *************************************************************
-// Inline operations for class CORBA::ORB_out
-// *************************************************************
-
-ACE_INLINE
-CORBA::ORB_out::ORB_out (CORBA::ORB_ptr &p)
- : ptr_ (p)
-{
- this->ptr_ = CORBA::ORB::_nil ();
-}
-
-ACE_INLINE
-CORBA::ORB_out::ORB_out (CORBA::ORB_var &p) // constructor from _var
- : ptr_ (p.out ())
-{
- CORBA::release (this->ptr_);
- this->ptr_ = CORBA::ORB::_nil ();
-}
-
-ACE_INLINE
-CORBA::ORB_out::ORB_out (const CORBA::ORB_out &p) // copy constructor
- : ptr_ (p.ptr_)
-{}
-
-ACE_INLINE CORBA::ORB_out &
-CORBA::ORB_out::operator= (CORBA::ORB_out &p)
-{
- this->ptr_ = p.ptr_;
- return *this;
-}
-
-ACE_INLINE CORBA::ORB_out &
-CORBA::ORB_out::operator= (const CORBA::ORB_var &p)
-{
- this->ptr_ = CORBA::ORB::_duplicate (p.ptr ());
- return *this;
-}
-
-ACE_INLINE CORBA::ORB_out &
-CORBA::ORB_out::operator= (CORBA::ORB_ptr p)
-{
- this->ptr_ = p;
- return *this;
-}
-
-ACE_INLINE
-CORBA::ORB_out::operator CORBA::ORB_ptr &() // cast
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr &
-CORBA::ORB_out::ptr (void) // ptr
-{
- return this->ptr_;
-}
-
-ACE_INLINE CORBA::ORB_ptr
-CORBA::ORB_out::operator-> (void)
-{
- return this->ptr_;
-}