00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef ACTIVATOR_OPTIONS_H
00016 #define ACTIVATOR_OPTIONS_H
00017
00018 #include "activator_export.h"
00019
00020 #include "ace/SString.h"
00021
00022 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00023 # pragma once
00024 #endif
00025
00026
00027
00028
00029
00030
00031
00032 class Activator_Export Activator_Options
00033 {
00034 public:
00035
00036 enum SERVICE_COMMAND {
00037 SC_NONE,
00038 SC_INSTALL,
00039 SC_REMOVE,
00040 SC_INSTALL_NO_LOCATOR
00041 };
00042
00043
00044
00045 enum ACTIVATOR_PROCESS
00046 {
00047 ENVIRONMENT_BUFFER = 16 * 1024
00048 };
00049
00050 Activator_Options ();
00051
00052
00053 int init (int argc, char *argv[]);
00054
00055 int init_from_registry();
00056
00057
00058 bool service (void) const;
00059
00060
00061
00062 bool notify_imr (void) const;
00063
00064
00065 unsigned int debug (void) const;
00066
00067
00068 const ACE_CString& ior_filename (void) const;
00069
00070
00071 SERVICE_COMMAND service_command(void) const;
00072
00073
00074 int save_registry_options ();
00075
00076 const char* cmdline(void) const;
00077
00078 const ACE_CString& name(void) const;
00079
00080 int env_buf_len (void) const;
00081
00082 private:
00083
00084 int parse_args (int &argc, char *argv[]);
00085
00086
00087 void print_usage (void) const;
00088
00089
00090 int load_registry_options ();
00091
00092 private:
00093
00094
00095 ACE_CString cmdline_;
00096
00097
00098 unsigned int debug_;
00099
00100
00101 ACE_CString ior_output_file_;
00102
00103
00104 bool service_;
00105
00106 bool notify_imr_;
00107
00108
00109 SERVICE_COMMAND service_command_;
00110
00111 ACE_CString name_;
00112
00113
00114 int env_buf_len_;
00115 };
00116
00117 #endif