diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/RegionInfo.cs | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index 24b9c89..24ec181 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -40,6 +40,7 @@ using OpenMetaverse.StructuredData; | |||
40 | 40 | ||
41 | namespace OpenSim.Framework | 41 | namespace OpenSim.Framework |
42 | { | 42 | { |
43 | [Serializable] | ||
43 | public class RegionLightShareData : ICloneable | 44 | public class RegionLightShareData : ICloneable |
44 | { | 45 | { |
45 | public bool valid = false; | 46 | public bool valid = false; |
@@ -102,6 +103,7 @@ namespace OpenSim.Framework | |||
102 | 103 | ||
103 | public bool commFailTF = false; | 104 | public bool commFailTF = false; |
104 | public ConfigurationMember configMember; | 105 | public ConfigurationMember configMember; |
106 | public string DataStore = String.Empty; | ||
105 | public string RegionFile = String.Empty; | 107 | public string RegionFile = String.Empty; |
106 | public bool isSandbox = false; | 108 | public bool isSandbox = false; |
107 | public bool Persistent = true; | 109 | public bool Persistent = true; |
@@ -222,10 +224,12 @@ namespace OpenSim.Framework | |||
222 | // | 224 | // |
223 | public RegionInfo(string description, XmlNode xmlNode, bool skipConsoleConfig, IConfigSource configSource) | 225 | public RegionInfo(string description, XmlNode xmlNode, bool skipConsoleConfig, IConfigSource configSource) |
224 | { | 226 | { |
225 | // m_configSource = configSource; | 227 | XmlElement elem = (XmlElement)xmlNode; |
226 | configMember = | 228 | string name = elem.GetAttribute("Name"); |
227 | new ConfigurationMember(xmlNode, description, loadConfigurationOptions, handleIncomingConfiguration, !skipConsoleConfig); | 229 | string xmlstr = "<Nini>" + xmlNode.OuterXml + "</Nini>"; |
228 | configMember.performConfigurationRetrieve(); | 230 | XmlConfigSource source = new XmlConfigSource(XmlReader.Create(new StringReader(xmlstr))); |
231 | ReadNiniConfig(source, name); | ||
232 | |||
229 | m_serverURI = string.Empty; | 233 | m_serverURI = string.Empty; |
230 | } | 234 | } |
231 | 235 | ||
@@ -707,6 +711,9 @@ namespace OpenSim.Framework | |||
707 | string location = String.Format("{0},{1}", m_regionLocX, m_regionLocY); | 711 | string location = String.Format("{0},{1}", m_regionLocX, m_regionLocY); |
708 | config.Set("Location", location); | 712 | config.Set("Location", location); |
709 | 713 | ||
714 | if (DataStore != String.Empty) | ||
715 | config.Set("Datastore", DataStore); | ||
716 | |||
710 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); | 717 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); |
711 | config.Set("InternalPort", m_internalEndPoint.Port); | 718 | config.Set("InternalPort", m_internalEndPoint.Port); |
712 | 719 | ||
@@ -921,6 +928,9 @@ namespace OpenSim.Framework | |||
921 | case "sim_location_y": | 928 | case "sim_location_y": |
922 | m_regionLocY = (uint) configuration_result; | 929 | m_regionLocY = (uint) configuration_result; |
923 | break; | 930 | break; |
931 | case "datastore": | ||
932 | DataStore = (string) configuration_result; | ||
933 | break; | ||
924 | case "internal_ip_address": | 934 | case "internal_ip_address": |
925 | IPAddress address = (IPAddress) configuration_result; | 935 | IPAddress address = (IPAddress) configuration_result; |
926 | m_internalEndPoint = new IPEndPoint(address, 0); | 936 | m_internalEndPoint = new IPEndPoint(address, 0); |
@@ -1077,6 +1087,11 @@ namespace OpenSim.Framework | |||
1077 | return regionInfo; | 1087 | return regionInfo; |
1078 | } | 1088 | } |
1079 | 1089 | ||
1090 | public int getInternalEndPointPort() | ||
1091 | { | ||
1092 | return m_internalEndPoint.Port; | ||
1093 | } | ||
1094 | |||
1080 | public Dictionary<string, object> ToKeyValuePairs() | 1095 | public Dictionary<string, object> ToKeyValuePairs() |
1081 | { | 1096 | { |
1082 | Dictionary<string, object> kvp = new Dictionary<string, object>(); | 1097 | Dictionary<string, object> kvp = new Dictionary<string, object>(); |