3 #include "ace/Get_Opt.h"
5 const ACE_TCHAR
*ior
= ACE_TEXT("file://test.ior");
8 parse_args (int argc
, ACE_TCHAR
*argv
[])
10 ACE_Get_Opt
get_opts (argc
, argv
, ACE_TEXT("k:"));
13 while ((c
= get_opts ()) != -1)
17 ior
= get_opts
.optarg
;
20 ACE_ERROR_RETURN ((LM_ERROR
,
31 ACE_TMAIN(int argc
, ACE_TCHAR
*argv
[])
36 CORBA::ORB_init (argc
, argv
, "client_sum_orb");
38 if (parse_args (argc
, argv
) != 0)
41 CORBA::Object_var obj
=
42 orb
->string_to_object (ior
);
44 ObjectReferenceTemplate::ORT_test_var server
=
45 ObjectReferenceTemplate::ORT_test::_narrow (obj
.in ());
47 if (CORBA::is_nil (server
.in ()))
49 ACE_ERROR_RETURN ((LM_ERROR
,
50 "Object reference <%s> is nil.\n",
55 CORBA::Boolean result
=
56 server
->request_server ();
59 ACE_DEBUG ((LM_DEBUG
, "Successful invocation\n"));
63 catch (const CORBA::Exception
& ex
)
65 ex
._tao_print_exception ("ORT test on client side :");