diff options
author | Melanie | 2009-10-19 21:58:51 +0100 |
---|---|---|
committer | Melanie | 2009-10-19 21:58:51 +0100 |
commit | ffd59868f5e2d797160b1bbfc13f3b4bac717b36 (patch) | |
tree | fb807a129a6e449ac17dadce15d7b27268c92c3f /OpenSim/Framework | |
parent | Merge branch 'master' into vehicles (diff) | |
parent | Minor formatting cleanup. (diff) | |
download | opensim-SC_OLD-ffd59868f5e2d797160b1bbfc13f3b4bac717b36.zip opensim-SC_OLD-ffd59868f5e2d797160b1bbfc13f3b4bac717b36.tar.gz opensim-SC_OLD-ffd59868f5e2d797160b1bbfc13f3b4bac717b36.tar.bz2 opensim-SC_OLD-ffd59868f5e2d797160b1bbfc13f3b4bac717b36.tar.xz |
Merge branch 'master' into vehicles
Diffstat (limited to 'OpenSim/Framework')
-rw-r--r-- | OpenSim/Framework/BlockingQueue.cs | 6 | ||||
-rw-r--r-- | OpenSim/Framework/IClientAPI.cs | 1 | ||||
-rw-r--r-- | OpenSim/Framework/RegionInfo.cs | 24 | ||||
-rw-r--r-- | OpenSim/Framework/Serialization/External/LandDataSerializer.cs | 24 | ||||
-rw-r--r-- | OpenSim/Framework/Servers/BaseOpenSimServer.cs | 2 |
5 files changed, 40 insertions, 17 deletions
diff --git a/OpenSim/Framework/BlockingQueue.cs b/OpenSim/Framework/BlockingQueue.cs index 857930a..3658161 100644 --- a/OpenSim/Framework/BlockingQueue.cs +++ b/OpenSim/Framework/BlockingQueue.cs | |||
@@ -67,8 +67,8 @@ namespace OpenSim.Framework | |||
67 | return m_pqueue.Dequeue(); | 67 | return m_pqueue.Dequeue(); |
68 | 68 | ||
69 | if (m_queue.Count > 0) | 69 | if (m_queue.Count > 0) |
70 | return m_queue.Dequeue(); | 70 | return m_queue.Dequeue(); |
71 | return default(T); | 71 | return default(T); |
72 | } | 72 | } |
73 | } | 73 | } |
74 | 74 | ||
@@ -121,7 +121,7 @@ namespace OpenSim.Framework | |||
121 | { | 121 | { |
122 | m_pqueue.Clear(); | 122 | m_pqueue.Clear(); |
123 | m_queue.Clear(); | 123 | m_queue.Clear(); |
124 | Monitor.Pulse(m_queueSync); | 124 | Monitor.Pulse(m_queueSync); |
125 | } | 125 | } |
126 | } | 126 | } |
127 | } | 127 | } |
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 29846f5..9fd043c 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -792,6 +792,7 @@ namespace OpenSim.Framework | |||
792 | event PickGodDelete OnPickGodDelete; | 792 | event PickGodDelete OnPickGodDelete; |
793 | event PickInfoUpdate OnPickInfoUpdate; | 793 | event PickInfoUpdate OnPickInfoUpdate; |
794 | event AvatarNotesUpdate OnAvatarNotesUpdate; | 794 | event AvatarNotesUpdate OnAvatarNotesUpdate; |
795 | event AvatarInterestUpdate OnAvatarInterestUpdate; | ||
795 | 796 | ||
796 | event MuteListRequest OnMuteListRequest; | 797 | event MuteListRequest OnMuteListRequest; |
797 | 798 | ||
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index d3a5357..a7315f5 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -303,6 +303,7 @@ namespace OpenSim.Framework | |||
303 | private int m_physPrimMax = 0; | 303 | private int m_physPrimMax = 0; |
304 | private bool m_clampPrimSize = false; | 304 | private bool m_clampPrimSize = false; |
305 | private int m_objectCapacity = 0; | 305 | private int m_objectCapacity = 0; |
306 | private string m_regionType = String.Empty; | ||
306 | 307 | ||
307 | 308 | ||
308 | // Apparently, we're applying the same estatesettings regardless of whether it's local or remote. | 309 | // Apparently, we're applying the same estatesettings regardless of whether it's local or remote. |
@@ -478,6 +479,11 @@ namespace OpenSim.Framework | |||
478 | get { return (byte)Util.ConvertMaturityToAccessLevel((uint)RegionSettings.Maturity); } | 479 | get { return (byte)Util.ConvertMaturityToAccessLevel((uint)RegionSettings.Maturity); } |
479 | } | 480 | } |
480 | 481 | ||
482 | public string RegionType | ||
483 | { | ||
484 | get { return m_regionType; } | ||
485 | } | ||
486 | |||
481 | public void SetEndPoint(string ipaddr, int port) | 487 | public void SetEndPoint(string ipaddr, int port) |
482 | { | 488 | { |
483 | IPAddress tmpIP = IPAddress.Parse(ipaddr); | 489 | IPAddress tmpIP = IPAddress.Parse(ipaddr); |
@@ -654,8 +660,8 @@ namespace OpenSim.Framework | |||
654 | 660 | ||
655 | MasterAvatarAssignedUUID = new UUID(masterAvatarUUID); | 661 | MasterAvatarAssignedUUID = new UUID(masterAvatarUUID); |
656 | 662 | ||
663 | m_regionType = config.GetString("RegionType", String.Empty); | ||
657 | 664 | ||
658 | |||
659 | // Prim stuff | 665 | // Prim stuff |
660 | // | 666 | // |
661 | m_nonphysPrimMax = config.GetInt("NonphysicalPrimMax", 256); | 667 | m_nonphysPrimMax = config.GetInt("NonphysicalPrimMax", 256); |
@@ -721,6 +727,9 @@ namespace OpenSim.Framework | |||
721 | 727 | ||
722 | if (ScopeID != UUID.Zero) | 728 | if (ScopeID != UUID.Zero) |
723 | config.Set("ScopeID", ScopeID.ToString()); | 729 | config.Set("ScopeID", ScopeID.ToString()); |
730 | |||
731 | if (RegionType != String.Empty) | ||
732 | config.Set("RegionType", RegionType); | ||
724 | } | 733 | } |
725 | 734 | ||
726 | public bool ignoreIncomingConfiguration(string configuration_key, object configuration_result) | 735 | public bool ignoreIncomingConfiguration(string configuration_key, object configuration_result) |
@@ -810,6 +819,9 @@ namespace OpenSim.Framework | |||
810 | 819 | ||
811 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, | 820 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, |
812 | "Scope ID for this region", ScopeID.ToString(), true); | 821 | "Scope ID for this region", ScopeID.ToString(), true); |
822 | |||
823 | configMember.addConfigurationOption("region_type", ConfigurationOption.ConfigurationTypes.TYPE_STRING, | ||
824 | "Region Type", String.Empty, true); | ||
813 | } | 825 | } |
814 | 826 | ||
815 | public void loadConfigurationOptions() | 827 | public void loadConfigurationOptions() |
@@ -873,6 +885,9 @@ namespace OpenSim.Framework | |||
873 | 885 | ||
874 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, | 886 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, |
875 | "Scope ID for this region", UUID.Zero.ToString(), true); | 887 | "Scope ID for this region", UUID.Zero.ToString(), true); |
888 | |||
889 | configMember.addConfigurationOption("region_type", ConfigurationOption.ConfigurationTypes.TYPE_STRING, | ||
890 | "Region Type", String.Empty, true); | ||
876 | } | 891 | } |
877 | 892 | ||
878 | public bool shouldMasterAvatarDetailsBeAsked(string configuration_key) | 893 | public bool shouldMasterAvatarDetailsBeAsked(string configuration_key) |
@@ -953,6 +968,9 @@ namespace OpenSim.Framework | |||
953 | case "scope_id": | 968 | case "scope_id": |
954 | ScopeID = (UUID)configuration_result; | 969 | ScopeID = (UUID)configuration_result; |
955 | break; | 970 | break; |
971 | case "region_type": | ||
972 | m_regionType = (string)configuration_result; | ||
973 | break; | ||
956 | } | 974 | } |
957 | 975 | ||
958 | return true; | 976 | return true; |
@@ -988,6 +1006,8 @@ namespace OpenSim.Framework | |||
988 | args["allow_alt_ports"] = OSD.FromBoolean(m_allow_alternate_ports); | 1006 | args["allow_alt_ports"] = OSD.FromBoolean(m_allow_alternate_ports); |
989 | if ((proxyUrl != null) && !proxyUrl.Equals("")) | 1007 | if ((proxyUrl != null) && !proxyUrl.Equals("")) |
990 | args["proxy_url"] = OSD.FromString(proxyUrl); | 1008 | args["proxy_url"] = OSD.FromString(proxyUrl); |
1009 | if (RegionType != String.Empty) | ||
1010 | args["region_type"] = OSD.FromString(RegionType); | ||
991 | 1011 | ||
992 | return args; | 1012 | return args; |
993 | } | 1013 | } |
@@ -1035,6 +1055,8 @@ namespace OpenSim.Framework | |||
1035 | m_allow_alternate_ports = args["allow_alt_ports"].AsBoolean(); | 1055 | m_allow_alternate_ports = args["allow_alt_ports"].AsBoolean(); |
1036 | if (args["proxy_url"] != null) | 1056 | if (args["proxy_url"] != null) |
1037 | proxyUrl = args["proxy_url"].AsString(); | 1057 | proxyUrl = args["proxy_url"].AsString(); |
1058 | if (args["region_type"] != null) | ||
1059 | m_regionType = args["region_type"].AsString(); | ||
1038 | } | 1060 | } |
1039 | 1061 | ||
1040 | public static RegionInfo Create(UUID regionID, string regionName, uint regX, uint regY, string externalHostName, uint httpPort, uint simPort, uint remotingPort, string serverURI) | 1062 | public static RegionInfo Create(UUID regionID, string regionName, uint regX, uint regY, string externalHostName, uint httpPort, uint simPort, uint remotingPort, string serverURI) |
diff --git a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs index a3bc5d1..ff0afc8 100644 --- a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs +++ b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs | |||
@@ -41,7 +41,7 @@ namespace OpenSim.Framework.Serialization.External | |||
41 | public class LandDataSerializer | 41 | public class LandDataSerializer |
42 | { | 42 | { |
43 | protected static UTF8Encoding m_utf8Encoding = new UTF8Encoding(); | 43 | protected static UTF8Encoding m_utf8Encoding = new UTF8Encoding(); |
44 | 44 | ||
45 | /// <summary> | 45 | /// <summary> |
46 | /// Reify/deserialize landData | 46 | /// Reify/deserialize landData |
47 | /// </summary> | 47 | /// </summary> |
@@ -52,7 +52,7 @@ namespace OpenSim.Framework.Serialization.External | |||
52 | { | 52 | { |
53 | return Deserialize(m_utf8Encoding.GetString(serializedLandData, 0, serializedLandData.Length)); | 53 | return Deserialize(m_utf8Encoding.GetString(serializedLandData, 0, serializedLandData.Length)); |
54 | } | 54 | } |
55 | 55 | ||
56 | /// <summary> | 56 | /// <summary> |
57 | /// Reify/deserialize landData | 57 | /// Reify/deserialize landData |
58 | /// </summary> | 58 | /// </summary> |
@@ -62,10 +62,10 @@ namespace OpenSim.Framework.Serialization.External | |||
62 | public static LandData Deserialize(string serializedLandData) | 62 | public static LandData Deserialize(string serializedLandData) |
63 | { | 63 | { |
64 | LandData landData = new LandData(); | 64 | LandData landData = new LandData(); |
65 | 65 | ||
66 | StringReader sr = new StringReader(serializedLandData); | 66 | StringReader sr = new StringReader(serializedLandData); |
67 | XmlTextReader xtr = new XmlTextReader(sr); | 67 | XmlTextReader xtr = new XmlTextReader(sr); |
68 | 68 | ||
69 | xtr.ReadStartElement("LandData"); | 69 | xtr.ReadStartElement("LandData"); |
70 | 70 | ||
71 | landData.Area = Convert.ToInt32( xtr.ReadElementString("Area")); | 71 | landData.Area = Convert.ToInt32( xtr.ReadElementString("Area")); |
@@ -106,7 +106,7 @@ namespace OpenSim.Framework.Serialization.External | |||
106 | pae.Time = Convert.ToDateTime( xtr.ReadElementString("Time")); | 106 | pae.Time = Convert.ToDateTime( xtr.ReadElementString("Time")); |
107 | pae.Flags = (AccessList)Convert.ToUInt32( xtr.ReadElementString("AccessList")); | 107 | pae.Flags = (AccessList)Convert.ToUInt32( xtr.ReadElementString("AccessList")); |
108 | xtr.ReadEndElement(); | 108 | xtr.ReadEndElement(); |
109 | 109 | ||
110 | landData.ParcelAccessList.Add(pae); | 110 | landData.ParcelAccessList.Add(pae); |
111 | } | 111 | } |
112 | } | 112 | } |
@@ -122,13 +122,13 @@ namespace OpenSim.Framework.Serialization.External | |||
122 | landData.OtherCleanTime = Convert.ToInt32( xtr.ReadElementString("OtherCleanTime")); | 122 | landData.OtherCleanTime = Convert.ToInt32( xtr.ReadElementString("OtherCleanTime")); |
123 | 123 | ||
124 | xtr.ReadEndElement(); | 124 | xtr.ReadEndElement(); |
125 | 125 | ||
126 | xtr.Close(); | 126 | xtr.Close(); |
127 | sr.Close(); | 127 | sr.Close(); |
128 | 128 | ||
129 | return landData; | 129 | return landData; |
130 | } | 130 | } |
131 | 131 | ||
132 | public static string Serialize(LandData landData) | 132 | public static string Serialize(LandData landData) |
133 | { | 133 | { |
134 | StringWriter sw = new StringWriter(); | 134 | StringWriter sw = new StringWriter(); |
@@ -137,8 +137,8 @@ namespace OpenSim.Framework.Serialization.External | |||
137 | 137 | ||
138 | xtw.WriteStartDocument(); | 138 | xtw.WriteStartDocument(); |
139 | xtw.WriteStartElement("LandData"); | 139 | xtw.WriteStartElement("LandData"); |
140 | 140 | ||
141 | xtw.WriteElementString("Area", Convert.ToString(landData.Area)); | 141 | xtw.WriteElementString("Area", Convert.ToString(landData.Area)); |
142 | xtw.WriteElementString("AuctionID", Convert.ToString(landData.AuctionID)); | 142 | xtw.WriteElementString("AuctionID", Convert.ToString(landData.AuctionID)); |
143 | xtw.WriteElementString("AuthBuyerID", landData.AuthBuyerID.ToString()); | 143 | xtw.WriteElementString("AuthBuyerID", landData.AuthBuyerID.ToString()); |
144 | xtw.WriteElementString("Category", Convert.ToString((sbyte)landData.Category)); | 144 | xtw.WriteElementString("Category", Convert.ToString((sbyte)landData.Category)); |
@@ -170,7 +170,7 @@ namespace OpenSim.Framework.Serialization.External | |||
170 | xtw.WriteEndElement(); | 170 | xtw.WriteEndElement(); |
171 | } | 171 | } |
172 | xtw.WriteEndElement(); | 172 | xtw.WriteEndElement(); |
173 | 173 | ||
174 | xtw.WriteElementString("PassHours", Convert.ToString(landData.PassHours)); | 174 | xtw.WriteElementString("PassHours", Convert.ToString(landData.PassHours)); |
175 | xtw.WriteElementString("PassPrice", Convert.ToString(landData.PassPrice)); | 175 | xtw.WriteElementString("PassPrice", Convert.ToString(landData.PassPrice)); |
176 | xtw.WriteElementString("SalePrice", Convert.ToString(landData.SalePrice)); | 176 | xtw.WriteElementString("SalePrice", Convert.ToString(landData.SalePrice)); |
@@ -184,7 +184,7 @@ namespace OpenSim.Framework.Serialization.External | |||
184 | 184 | ||
185 | xtw.Close(); | 185 | xtw.Close(); |
186 | sw.Close(); | 186 | sw.Close(); |
187 | 187 | ||
188 | return sw.ToString(); | 188 | return sw.ToString(); |
189 | } | 189 | } |
190 | } | 190 | } |
diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index 845a9fe..0d93ff7 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs | |||
@@ -246,7 +246,7 @@ namespace OpenSim.Framework.Servers | |||
246 | foreach (ProcessThread t in threads) | 246 | foreach (ProcessThread t in threads) |
247 | { | 247 | { |
248 | sb.Append("ID: " + t.Id + ", TotalProcessorTime: " + t.TotalProcessorTime + ", TimeRunning: " + | 248 | sb.Append("ID: " + t.Id + ", TotalProcessorTime: " + t.TotalProcessorTime + ", TimeRunning: " + |
249 | (DateTime.Now - t.StartTime) + ", Pri: " + t.CurrentPriority + ", State: " + t.ThreadState ); | 249 | (DateTime.Now - t.StartTime) + ", Pri: " + t.CurrentPriority + ", State: " + t.ThreadState); |
250 | if (t.ThreadState == System.Diagnostics.ThreadState.Wait) | 250 | if (t.ThreadState == System.Diagnostics.ThreadState.Wait) |
251 | sb.Append(", Reason: " + t.WaitReason + Environment.NewLine); | 251 | sb.Append(", Reason: " + t.WaitReason + Environment.NewLine); |
252 | else | 252 | else |