blob: d0f3245c5ebc61aa2e7a144a0e76e3be786b16d8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
|
// -*- C++ -*-
// $Id$
#ifndef IFR_DII_CLIENT_H
#define IFR_DII_CLIENT_H
#include "tao/DynamicInterface/Request.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
#include "tao/IFR_Client/IFR_BasicC.h"
class IFR_DII_Client
{
public:
IFR_DII_Client (void);
~IFR_DII_Client (void);
int init (int argc,
char *argv[]
ACE_ENV_ARG_DECL);
// Initialize the client.
int run (void);
// Run the client.
private:
int parse_args (int argc,
char *argv[]);
// Process the command line arguments.
int find_interface_def (void);
// Query the object reference to get its InterfaceDef in the IFR.
int lookup_interface_def (void);
// Look up the InterfaceDef by name in the IFR.
void get_operation_def (void);
// Find the desired operation in the interface definition.
void create_dii_request (void);
// Query the interface definition to get the info needed
// to construct a CORBA::Request.
void invoke_and_display (void);
// Do the invocation and display the results.
CORBA::ORB_var orb_;
// Reference to our ORB.
CORBA::Repository_var repo_;
// Reference to the Interface Repository.
CORBA::Object_var target_;
// Reference to the target object.
CORBA::InterfaceDef_var target_def_;
// Repository entry corresponding to target_.
CORBA::OperationDef_var op_;
// Reference to the discovered operation.
CORBA::TypeCode_var result_;
// Type of the return value, if any.
CORBA::Request_var req_;
// DII request holder.
CORBA::String_var namespace_name;
CORBA::String_var interface_name;
CORBA::String_var op_name;
// Things that we will be searching for in the repository.
bool lookup_by_name_;
// Are we looking up info on the target object by querying the
// IFR directly with the target's name, or indirectly
// by calling _get_interface() on the target object?
bool debug_;
// Display results and debugging info?
};
#endif /* IFR_DII_CLIENT_H */
|