CORBA 2.3.3 Programmer's Reference (NonStop CORBA 2.3.7+)
expected under CORBA 2.3 because, by default, CORBA 2.3 is backward compatible with NonStop
DOM 2.0. If your application is using no reference counting at all for a servant, the servant must override
the method Servant::_uses_which_ref_type() with an implementation that returns a value of
zero.
NSDOM_ServantBase::NSDOM_Ref_Type
NSDOM_ServantBase::_uses_which_ref_type()
{
return Uses_NSDOM_ref_count;
// must be overridden by OMG compliant programs which do not use
// reference counting.
}
void
NSDOM_ServantBase::_add_nsd_ref()
{
if (_uses_which_ref_type() == Uses_NSDOM_ref_count)
{
CORBA::Object::_duplicate( this->_this_reference() );
} else
this->_add_ref();
}
void
NSDOM_ServantBase::_remove_nsd_ref()
{
if (_uses_which_ref_type() == Uses_NSDOM_ref_count)
{
CORBA::release( this->_this_reference() );
} else
this->_remove_ref();
}
Prev Up Next
Chapter 2. Interoperability and
Interworking
Home
Chapter 4. Java Language Mapping