Merge pull request #1844 from jrw972/monterey
[ACE_TAO.git] / TAO / examples / Load_Balancing / Load_Balancing_Service.h
blobdb53e83d4bc00a6d32d55ecdcb49aefd1b8e42d3
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Load_Balancing_Service.h
7 * Driver for Load Balancing service.
9 * @author Marina Spivak <marina@cs.wustl.edu>
11 //=============================================================================
14 #ifndef LOAD_BALANCING_SERVICE_H_
15 #define LOAD_BALANCING_SERVICE_H_
17 #include "tao/Utils/ORB_Manager.h"
19 #if !defined (ACE_LACKS_PRAGMA_ONCE)
20 # pragma once
21 #endif /* ACE_LACKS_PRAGMA_ONCE */
23 /**
24 * @class Load_Balancing_Service
26 * Server, which creates and initializes a
27 * <Load_Balancer::Object_Group_Factory>
28 * object, and runs the orb loop.
30 class Load_Balancing_Service
32 public:
34 /// Default constructor.
35 Load_Balancing_Service (void);
37 /// Destructor.
38 ~Load_Balancing_Service (void);
40 /// Initialize the <Load_Balancing_Service>: initializes the ORB, parses
41 /// arguments, creates a servant ...
42 int init (int argc, ACE_TCHAR *argv[]);
44 /// Run the server.
45 int run (void);
47 private:
48 /// Parses the commandline arguments.
49 int parse_args (int argc, ACE_TCHAR *argv[]);
51 /// The ORB manager.
52 TAO_ORB_Manager orb_manager_;
54 /// File to output the <Object_Group_Factory> IOR.
55 FILE *ior_output_file_;
58 #endif /* LOAD_BALANCING_SERVICE_H_ */