NVList.inl

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // $Id: NVList.inl 77768 2007-03-22 19:53:25Z johnnyw $
00004 
00005 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00006 
00007 ACE_INLINE CORBA::Boolean
00008 CORBA::is_nil (CORBA::NamedValue_ptr nv)
00009 {
00010   return nv == 0;
00011 }
00012 
00013 ACE_INLINE void
00014 CORBA::release (CORBA::NamedValue_ptr nv)
00015 {
00016   if (nv)
00017     nv->_decr_refcnt ();
00018 }
00019 
00020 // *************************************************************
00021 
00022 ACE_INLINE
00023 CORBA::NamedValue::NamedValue (void)
00024   : refcount_ (1),
00025     flags_ (0),
00026     name_ (0)
00027 {
00028 }
00029 
00030 ACE_INLINE
00031 const char *
00032 CORBA::NamedValue::name (void) const
00033 {
00034   return this->name_;
00035 }
00036 
00037 ACE_INLINE
00038 CORBA::Any_ptr
00039 CORBA::NamedValue::value (void) const
00040 {
00041   return const_cast<CORBA::Any_ptr> (&this->any_);
00042 }
00043 
00044 ACE_INLINE
00045 CORBA::Flags
00046 CORBA::NamedValue::flags (void) const
00047 {
00048   return this->flags_;
00049 }
00050 
00051 ACE_INLINE
00052 CORBA::NamedValue *
00053 CORBA::NamedValue::_duplicate (CORBA::NamedValue * x)
00054 {
00055   if (x != 0)
00056     {
00057       x->_incr_refcnt ();
00058     }
00059 
00060   return x;
00061 }
00062 
00063 ACE_INLINE
00064 CORBA::NamedValue*
00065 CORBA::NamedValue::_nil (void)
00066 {
00067   return 0;
00068 }
00069 
00070 // *************************************************************
00071 
00072 ACE_INLINE
00073 CORBA::Boolean
00074 CORBA::is_nil (CORBA::NVList_ptr nvl)
00075 {
00076   return (CORBA::Boolean) (nvl == 0);
00077 }
00078 
00079 ACE_INLINE
00080 void
00081 CORBA::release (CORBA::NVList_ptr nvl)
00082 {
00083   if (nvl)
00084     {
00085       nvl->_decr_refcnt ();
00086     }
00087 }
00088 
00089 // ****************************************************************
00090 
00091 ACE_INLINE
00092 CORBA::NVList::NVList (void)
00093   : max_ (0),
00094     refcount_ (1),
00095     incoming_ (0),
00096     incoming_flag_ (0)
00097 {
00098 }
00099 
00100 ACE_INLINE
00101 CORBA::ULong
00102 CORBA::NVList::count (void) const
00103 {
00104   (const_cast<CORBA::NVList *> (this))->evaluate ();
00105 
00106   return this->max_;
00107 }
00108 
00109 ACE_INLINE
00110 CORBA::NVList *
00111 CORBA::NVList::_duplicate (CORBA::NVList * x)
00112 {
00113   if (x != 0)
00114     {
00115       x->_incr_refcnt ();
00116     }
00117 
00118   return x;
00119 }
00120 
00121 ACE_INLINE
00122 CORBA::NVList *
00123 CORBA::NVList::_nil (void)
00124 {
00125   return 0;
00126 }
00127 
00128 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Sun Jan 27 13:21:06 2008 for TAO_AnyTypeCode by doxygen 1.3.6