[omniORB] Trouble accessing existing CORBA service from Python

Duncan Grisby duncan at grisby.org
Mon Apr 12 21:45:56 BST 2004


On Wednesday 7 April, Joel Wagner wrote:

> One problem I've run into is that some enums used between client and server
> were implemented in .h files.  Good or bad, this was done to get around the
> CORBA IDL restriction that enums can not be assigned values.  

Do you mean that the IDL said enum, but you redefined the enum values
elsewhere?  If so, you won't be able to talk to the server directly
since omniORBpy will check that the enum values are in the range
expected from the IDL, not the values you have assigned them. The
work-around will be to redefine the IDL to use unsigned long.

> What possibilities exist for accessing the enums of a .h file from a Python
> script?

You might have some luck with SWIG, but I don't know. Depending on how
clean your .h files are, you can probably do it with some simple
regular expressions.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan at grisby.org     --
   -- http://www.grisby.org --



More information about the omniORB-list mailing list