[omniORB] newbie:python dictionary

Luke Deller ldeller at xplantechnology.com
Wed Feb 22 10:26:44 GMT 2006


Hi Bryan,

On Tue, 2006-02-21 at 09:24 -0600, Green Bryan - bgreen wrote:
>    I have a python script that builds a dictionary data structure.  We
> are porting our python programs to omniORBpy and are wondering how to
> return a dictionary that will then be passed to another service?

CORBA doesn't support dictionaries.

One way to transfer python dictionaries across CORBA is to convert the
dictionary to a sequence of CORBA structs, where each struct represents
a (key, value) pair.  The dictionary can be reassembled from this at the
other end.

You can see which types are available for use with CORBA by checking out
section 3.11 of the CORBA spec:

http://www.omg.org/technology/documents/formal/corba_iiop.htm

... and you can figure out how these CORBA types map to python by
checking out section 1.3 of the python language mapping:

http://www.omg.org/technology/documents/formal/python.htm

Regards,
Luke.


**********************************************************************************************

Important Note
This email (including any attachments) contains information which is
confidential and may be subject to legal privilege.  If you are not
the intended recipient you must not use, distribute or copy this
email.  If you have received this email in error please notify the
sender immediately and delete this email. Any views expressed in this
email are not necessarily the views of XPlan Technology.

It is the duty of the recipient to virus scan and otherwise test the
information provided before loading onto any computer system.
Xplan Technology does not warrant that the
information is free of a virus or any other defect or error.
**********************************************************************************************




More information about the omniORB-list mailing list