[omniORB] Int. rep ID portability
Duncan Grisby
dgrisby@uk.research.att.com
Tue, 05 Dec 2000 10:55:12 +0000
On Tuesday 5 December, "Renzo Tomaselli" wrote:
> I'm using throughout my code Intf. rep. ID as generated by
> OmniIDL(2) compilers. So for an interface Foo in a module Bar, I use
> Bar_Foo_IntfRepoID as a constant string.
> Now I'm not quite sure anymore how much this is portable, indeed I could not
> find any syntax reference in Corba 2.3 specs for such names.
The Bar_Foo_IntfRepoID is omniORB 2 specific. It no longer exists in
omniORB 3, let alone other ORBs.
> An alternative and portable approach should be (as I must do in python)
> through Bar::_tc_Foo::id().
Yes, that is the portable way to do it.
For Python, it is not portable to use Bar._tc_Foo, since the _tc
TypeCodes are not part of the standard. You can get the repository id
for a type with CORBA.id(Bar.Foo), and the TypeCode with
CORBA.TypeCode(repoid).
Cheers,
Duncan.
--
-- Duncan Grisby \ Research Engineer --
-- AT&T Laboratories Cambridge --
-- http://www.uk.research.att.com/~dpg1 --