Merge pull request #1551 from DOCGroup/plm_jira_333
[ACE_TAO.git] / TAO / orbsvcs / examples / Notify / Lanes / Supplier_Client.h
blobd3cadb14fee39fe6b23b0702e6f409ff5bdbfa26
1 /* -*- C++ -*- */
2 /**
3 * @file Supplier_Client.h
5 * @author Pradeep Gore <pradeep@oomworks.com>
6 */
8 #ifndef TAO_Notify_SUPPLIER_CLIENT_H
9 #define TAO_Notify_SUPPLIER_CLIENT_H
11 #include /**/ "ace/pre.h"
12 #include "ace/Task.h"
13 #include "ace/SString.h"
15 #include "ORB_Objects.h"
17 class TAO_Notify_Lanes_Supplier;
19 /**
20 * @class TAO_Notify_Lanes_Supplier_Client
22 * @brief Supplier Client
24 class TAO_Notify_Lanes_Supplier_Client : public ACE_Task_Base
26 public:
27 /// Constructor
28 TAO_Notify_Lanes_Supplier_Client (TAO_Notify_ORB_Objects& orb_objects);
30 /// Destructor
31 ~TAO_Notify_Lanes_Supplier_Client ();
33 /// Init
34 void initialize (void);
36 /// Run
37 void run (void);
39 /// Parse Args
40 int parse_args (int argc, ACE_TCHAR *argv[]);
42 /// The thread entry point.
43 virtual int svc (void);
45 protected:
46 /// Create an EC
47 CosNotifyChannelAdmin::EventChannel_ptr create_ec (void);
49 /// Write ior to file.
50 void write_ior (void);
52 /// ORB Objects.
53 TAO_Notify_ORB_Objects orb_objects_;
55 /// Supplier that sends events.
56 TAO_Notify_Lanes_Supplier* supplier_;
58 /// The Number of consumers that we expect to send an event to.
59 int consumer_count_;
61 /// Name of the file to write the supplier ior to.
62 ACE_TString ior_file_name_;
65 #include /**/ "ace/post.h"
66 #endif /* TAO_Notify_SUPPLIER_CLIENT_H */