[omniORB] Problem with method definitions

Luke Deller ldeller at xplantechnology.com
Tue Mar 27 10:41:36 BST 2007


Hi David,

...
> In the Implementation class I define this method: 
> bool RequestCreateEntity(EntityCreateData EntityData,
> long EntityId ) 
...

As you have noticed from the error messages and the generated skeleton
files, the first parameter of your C++ function needs to be of type
"const EntityCreateData &".  This is more efficient than
"EntityCreateData" because it doesn't require the whole struct to be
copied when the function is called.

There's a helpful table in the C++ Language Mapping Specification
(version 1.1) which shows the C++ type that you need in your function
signature for different IDL types.  It's called "Table 1-3" and is
spread over pages 1-106 and 1-107, in section 1.22.1 "Operation
Parameters and Signatures".  You can get this document from here:
    http://www.omg.org/technology/documents/formal/c++.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