[omniORB] CORBA::Any_var
Duncan Grisby
dgrisby@uk.research.att.com
Fri, 11 Jan 2002 17:27:35 +0000
On Friday 11 January, Ken Feuerman wrote:
> Ah, right, I guess the real question then is: Is there any (nice?
> official?) way to tell if any of the T_var types has been
> initialized with a corresponding non-NULL T_ptr? I take it from
> your previous message that the answer is "no", but that one must
> resort to using operator->() explicitly?
No, there's no way to tell if a T_var has been initialised. I imagine
that calling operator->() will work with all ORBs, but the C++ mapping
says
"The overloaded operator-> returns the T* held by the T_var, but
retains ownership of it. Compliant applications may not call this
function unless the T_var has been initialised with a valid
non-null T* or T_var."
So there's no officially compliant way of checking. Oh well.
Cheers,
Duncan.
--
-- Duncan Grisby \ Research Engineer --
-- AT&T Laboratories Cambridge --
-- http://www.uk.research.att.com/~dpg1 --