[omniORB] Python mapping for IDL struct

ondrej@frcatel.fri.utc.sk ondrej@frcatel.fri.utc.sk
Mon Mar 10 14:03:02 2003


Hi everybody,

 I am writing a small content management system and at this moment I am
developing a session manager. I have an IDL like

module Open1to1 {

  typedef long IPAddress[4];

 interface SessionManager {
	string enterSession(in long time,in IPAddress ip);
 };
};

I would like to write a Python client to server implementing this
interface (SessionManager).

I do standard stuff in startup (proved to work). The issue is, that when I
try to create a variable to hold input data for enterSession() call, I get
error.

ip = Open1to1.IPAddress()

Traceback (most recent call last):
  File "./create_session.py", line 34, in ?
    ip = Open1to1.IPAddress();
  File "./session_manager_idl.py", line 49, in __init__
    raise RuntimeError("Cannot construct objects of this type.")
RuntimeError: Cannot construct objects of this type.

Why am I receiving that error message ?

				Ondrej