/usr/include/tao/Utils/RIR_Narrow.cpp is in libtao-dev 6.0.1-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | // $Id: RIR_Narrow.cpp 76874 2007-02-02 14:12:41Z johnnyw $
#ifndef TAO_UTILS_RIR_NARROW_CPP
#define TAO_UTILS_RIR_NARROW_CPP
#include "tao/Utils/RIR_Narrow.h"
#include "tao/SystemException.h"
#include <stdexcept>
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
template<class T> typename TAO::Utils::RIR_Narrow<T>::_ptr_type
TAO::Utils::RIR_Narrow<T>::narrow (CORBA::ORB_ptr orb, char const * id)
{
CORBA::Object_var object =
orb->resolve_initial_references (id);
return RIR_Narrow<T>::narrow_object (object.in ());
}
template<class T> typename TAO::Utils::RIR_Narrow<T>::_ptr_type
TAO::Utils::RIR_Narrow<T>::narrow (PortableInterceptor::ORBInitInfo_ptr info,
char const * id)
{
CORBA::Object_var object = info->resolve_initial_references (id);
return RIR_Narrow<T>::narrow_object (object.in ());
}
template<class T> typename TAO::Utils::RIR_Narrow<T>::_ptr_type
TAO::Utils::RIR_Narrow<T>::narrow_object (CORBA::Object_ptr object)
{
_var_type narrowed_object = T::_narrow (object);
if (CORBA::is_nil (narrowed_object.in ()))
{
throw ::CORBA::INV_OBJREF ();
}
return narrowed_object._retn ();
}
TAO_END_VERSIONED_NAMESPACE_DECL
#endif /*TAO_UTILS_RIR_NARROW_CPP*/
|