2-81
DSOM Framework Reference
invoke Method
Purpose
Invokes a Request synchronously, waiting for the response.
IDL Syntax
ORBStatus invoke (
in Flags invoke_flags);
Description
The invoke method sends a Request synchronously, waiting for the response.
Parameters
receiver A pointer to a Request object.
env A pointer to the Environment structure for the method caller.
invoke_flags A Flags bitmask (unsigned long) representing control information for the
invoke method. There are currently no flags defined for the invoke
method.
Return Value
The invoke method returns an ORBStatus value representing the return code of the
operation.
Example
#include <somd.h>
#include <repostry.h>
#include <intfacdf.h>
#include <foo.h> /* provided by user */
/* assume following method declaration in interface Foo:
* long methodLong (in long inLong,inout long inoutLong);
* then the following code builds and then invokes
* a request to execute the call:
* result = methodLong(fooObj, &ev, 100,200);
* using the DII.
*/
Environment ev;
OperationDef opdef;
Description desc;
OperationDescription *opdesc;
NVList arglist;
long rc;
long value1 = 100;
long value2 = 200;
Foo fooObj;
Request reqObj;
NamedValue result;
Identifier name;
TypeCode tc;
void *dummy;
long dummylen;
Flags flags;
Kommentare zu diesen Handbüchern