Merge pull request #1551 from DOCGroup/plm_jira_333
[ACE_TAO.git] / TAO / orbsvcs / tests / FT_App / FT_Creator.h
blob45bb89e0370f891895c8b4895af2927f92f5d0b9
1 /* -*- C++ -*- */
2 //=============================================================================
3 /**
4 * @file FT_Creator.h
6 * This file is part of Fault Tolerant CORBA.
7 * Main wrapped around TAO_Object_Group_Creator
9 * @author Dale Wilson <wilson_d@ociweb.com>
11 //=============================================================================
13 #ifndef FT_CREATOR_H
14 #define FT_CREATOR_H
16 #include /**/ "ace/pre.h"
18 #include <ace/ACE.h>
20 #if !defined (ACE_LACKS_PRAGMA_ONCE)
21 # pragma once
22 #endif /* ACE_LACKS_PRAGMA_ONCE */
24 #include "TAO_Object_Group_Creator.h"
25 #include "ace/OS_NS_stdio.h"
27 namespace FTAPP
29 class FT_Creator
31 typedef ACE_Vector<ACE_CString> StringVec;
32 public:
33 ///////////////////////////
34 // construction/destruction
35 FT_Creator ();
37 ~FT_Creator ();
39 /////////////////
40 // initialization
41 int parse_args (int argc, ACE_TCHAR *argv[]);
43 int init (CORBA::ORB_ptr orb);
45 ////////////
46 // execution
47 int run (void);
49 ////////////
50 // shut down
51 int fini ();
53 /////////////////
54 // implementation
55 private:
56 void usage (FILE* out)const;
58 ////////////////////
59 // forbidden methods
60 private:
61 FT_Creator (const FT_Creator & rhs);
62 FT_Creator & operator = (const FT_Creator & rhs);
64 ////////////////
65 // Data members
66 private:
68 TAO::Object_Group_Creator creator_;
69 CORBA::ORB_var orb_;
70 const ACE_TCHAR * registry_ior_;
71 StringVec create_roles_;
72 StringVec unregister_roles_;
75 CosNaming::NamingContext_var naming_context_;
77 ::FT::ReplicationManager_var replication_manager_;
78 /**
79 * bool: true if we have a real replication manager
81 int have_replication_manager_;
83 /**
84 * bool: true if we should write individual IOR files
86 int write_iors_;
88 /**
89 * bool: true if we should write IOGR to a file
91 int write_iogr_;
93 /**
94 * bool: true if we should write IOGR to a Name Service
96 int ns_register_;
98 /**
99 * sequence number applied to created IOGRs
101 size_t iogr_seq_;
104 * prefix for names
106 ACE_CString prefix_;
111 } // namespace TAO
113 #include /**/ "ace/post.h"
115 #endif // FT_CREATOR_H