aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/MessageServerConfig.cs
diff options
context:
space:
mode:
authorAdam Frisby2008-04-29 14:04:55 +0000
committerAdam Frisby2008-04-29 14:04:55 +0000
commit375163a6fece8b3a57c7555246abe8338223a599 (patch)
tree163001ca96a4b4d08589e9772f78510677d5d0dc /OpenSim/Framework/MessageServerConfig.cs
parentPatch from Melanie: 0001087: Crash to bash de-linking objects. Thanks Melanie! (diff)
downloadopensim-SC_OLD-375163a6fece8b3a57c7555246abe8338223a599.zip
opensim-SC_OLD-375163a6fece8b3a57c7555246abe8338223a599.tar.gz
opensim-SC_OLD-375163a6fece8b3a57c7555246abe8338223a599.tar.bz2
opensim-SC_OLD-375163a6fece8b3a57c7555246abe8338223a599.tar.xz
* Spring cleaning.
* Added new generic "Location" class to handle 2D integer locations. Going to use it to replace all RegionHandle and X,Y coordinate references throughout the entire project. You have been warned.
Diffstat (limited to 'OpenSim/Framework/MessageServerConfig.cs')
-rw-r--r--OpenSim/Framework/MessageServerConfig.cs60
1 files changed, 27 insertions, 33 deletions
diff --git a/OpenSim/Framework/MessageServerConfig.cs b/OpenSim/Framework/MessageServerConfig.cs
index dbc06db..c378d27 100644
--- a/OpenSim/Framework/MessageServerConfig.cs
+++ b/OpenSim/Framework/MessageServerConfig.cs
@@ -34,25 +34,21 @@ namespace OpenSim.Framework
34 /// </summary> 34 /// </summary>
35 public class MessageServerConfig 35 public class MessageServerConfig
36 { 36 {
37 public string DefaultStartupMsg = String.Empty;
38 public string UserServerURL = String.Empty;
39 public string UserSendKey = String.Empty;
40 public string UserRecvKey = String.Empty;
41
42 public string GridServerURL = String.Empty;
43 public string GridSendKey = String.Empty;
44 public string GridRecvKey = String.Empty;
45 public string MessageServerIP = String.Empty;
46
47 public string DatabaseProvider = String.Empty;
48 public string GridCommsProvider = String.Empty;
49
50 public static uint DefaultHttpPort = 8006; 37 public static uint DefaultHttpPort = 8006;
51 public static bool DefaultHttpSSL = false; 38 public static bool DefaultHttpSSL = false;
39 private ConfigurationMember configMember;
40 public string DatabaseProvider = String.Empty;
41 public string DefaultStartupMsg = String.Empty;
42 public string GridCommsProvider = String.Empty;
43 public string GridRecvKey = String.Empty;
44 public string GridSendKey = String.Empty;
45 public string GridServerURL = String.Empty;
52 public uint HttpPort = DefaultHttpPort; 46 public uint HttpPort = DefaultHttpPort;
53 public bool HttpSSL = DefaultHttpSSL; 47 public bool HttpSSL = DefaultHttpSSL;
54 48 public string MessageServerIP = String.Empty;
55 private ConfigurationMember configMember; 49 public string UserRecvKey = String.Empty;
50 public string UserSendKey = String.Empty;
51 public string UserServerURL = String.Empty;
56 52
57 public MessageServerConfig(string description, string filename) 53 public MessageServerConfig(string description, string filename)
58 { 54 {
@@ -60,9 +56,9 @@ namespace OpenSim.Framework
60 new ConfigurationMember(filename, description, loadConfigurationOptions, handleIncomingConfiguration, true); 56 new ConfigurationMember(filename, description, loadConfigurationOptions, handleIncomingConfiguration, true);
61 configMember.performConfigurationRetrieve(); 57 configMember.performConfigurationRetrieve();
62 } 58 }
59
63 public void loadConfigurationOptions() 60 public void loadConfigurationOptions()
64 { 61 {
65
66 configMember.addConfigurationOption("default_user_server", 62 configMember.addConfigurationOption("default_user_server",
67 ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, 63 ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
68 "Default User Server URI", 64 "Default User Server URI",
@@ -82,7 +78,7 @@ namespace OpenSim.Framework
82 78
83 configMember.addConfigurationOption("database_provider", ConfigurationOption.ConfigurationTypes.TYPE_STRING, 79 configMember.addConfigurationOption("database_provider", ConfigurationOption.ConfigurationTypes.TYPE_STRING,
84 "DLL for database provider", "OpenSim.Data.MySQL.dll", false); 80 "DLL for database provider", "OpenSim.Data.MySQL.dll", false);
85 81
86 configMember.addConfigurationOption("region_comms_provider", ConfigurationOption.ConfigurationTypes.TYPE_STRING, 82 configMember.addConfigurationOption("region_comms_provider", ConfigurationOption.ConfigurationTypes.TYPE_STRING,
87 "DLL for comms provider", "OpenSim.Region.Communications.OGS1.dll", false); 83 "DLL for comms provider", "OpenSim.Region.Communications.OGS1.dll", false);
88 84
@@ -91,51 +87,49 @@ namespace OpenSim.Framework
91 configMember.addConfigurationOption("http_ssl", ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN, 87 configMember.addConfigurationOption("http_ssl", ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN,
92 "Use SSL? true/false", DefaultHttpSSL.ToString(), false); 88 "Use SSL? true/false", DefaultHttpSSL.ToString(), false);
93 configMember.addConfigurationOption("published_ip", ConfigurationOption.ConfigurationTypes.TYPE_STRING, 89 configMember.addConfigurationOption("published_ip", ConfigurationOption.ConfigurationTypes.TYPE_STRING,
94 "My Published IP Address", "127.0.0.1", false); 90 "My Published IP Address", "127.0.0.1", false);
95
96 } 91 }
97 92
98 public bool handleIncomingConfiguration(string configuration_key, object configuration_result) 93 public bool handleIncomingConfiguration(string configuration_key, object configuration_result)
99 { 94 {
100 switch (configuration_key) 95 switch (configuration_key)
101 { 96 {
102
103 case "default_user_server": 97 case "default_user_server":
104 UserServerURL = (string)configuration_result; 98 UserServerURL = (string) configuration_result;
105 break; 99 break;
106 case "user_send_key": 100 case "user_send_key":
107 UserSendKey = (string)configuration_result; 101 UserSendKey = (string) configuration_result;
108 break; 102 break;
109 case "user_recv_key": 103 case "user_recv_key":
110 UserRecvKey = (string)configuration_result; 104 UserRecvKey = (string) configuration_result;
111 break; 105 break;
112 case "default_grid_server": 106 case "default_grid_server":
113 GridServerURL = (string)configuration_result; 107 GridServerURL = (string) configuration_result;
114 break; 108 break;
115 case "grid_send_key": 109 case "grid_send_key":
116 GridSendKey = (string)configuration_result; 110 GridSendKey = (string) configuration_result;
117 break; 111 break;
118 case "grid_recv_key": 112 case "grid_recv_key":
119 GridRecvKey = (string)configuration_result; 113 GridRecvKey = (string) configuration_result;
120 break; 114 break;
121 case "database_provider": 115 case "database_provider":
122 DatabaseProvider = (string)configuration_result; 116 DatabaseProvider = (string) configuration_result;
123 break; 117 break;
124 case "http_port": 118 case "http_port":
125 HttpPort = (uint)configuration_result; 119 HttpPort = (uint) configuration_result;
126 break; 120 break;
127 case "http_ssl": 121 case "http_ssl":
128 HttpSSL = (bool)configuration_result; 122 HttpSSL = (bool) configuration_result;
129 break; 123 break;
130 case "region_comms_provider": 124 case "region_comms_provider":
131 GridCommsProvider = (string)configuration_result; 125 GridCommsProvider = (string) configuration_result;
132 break; 126 break;
133 case "published_ip": 127 case "published_ip":
134 MessageServerIP = (string)configuration_result; 128 MessageServerIP = (string) configuration_result;
135 break; 129 break;
136 } 130 }
137 131
138 return true; 132 return true;
139 } 133 }
140 } 134 }
141} 135} \ No newline at end of file