aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Communications
diff options
context:
space:
mode:
authordiva2009-03-18 16:37:26 +0000
committerdiva2009-03-18 16:37:26 +0000
commita7d610ffcca8d707c7f9e9fdd7ad1477981ec2a9 (patch)
tree4f8a0c98e680fba6af670650993ecebdad4c8de2 /OpenSim/Region/Communications
parentAdd an event to process undelivered IMs (diff)
downloadopensim-SC_OLD-a7d610ffcca8d707c7f9e9fdd7ad1477981ec2a9.zip
opensim-SC_OLD-a7d610ffcca8d707c7f9e9fdd7ad1477981ec2a9.tar.gz
opensim-SC_OLD-a7d610ffcca8d707c7f9e9fdd7ad1477981ec2a9.tar.bz2
opensim-SC_OLD-a7d610ffcca8d707c7f9e9fdd7ad1477981ec2a9.tar.xz
Adds support for unlink-region command in hypergrid.
Diffstat (limited to 'OpenSim/Region/Communications')
-rw-r--r--OpenSim/Region/Communications/Hypergrid/HGGridServices.cs41
-rw-r--r--OpenSim/Region/Communications/Local/LocalBackEndServices.cs32
-rw-r--r--OpenSim/Region/Communications/OGS1/OGS1GridServices.cs22
3 files changed, 95 insertions, 0 deletions
diff --git a/OpenSim/Region/Communications/Hypergrid/HGGridServices.cs b/OpenSim/Region/Communications/Hypergrid/HGGridServices.cs
index 4493591..5b3343a 100644
--- a/OpenSim/Region/Communications/Hypergrid/HGGridServices.cs
+++ b/OpenSim/Region/Communications/Hypergrid/HGGridServices.cs
@@ -258,6 +258,47 @@ namespace OpenSim.Region.Communications.Hypergrid
258 return null; 258 return null;
259 } 259 }
260 260
261 public virtual RegionInfo RequestNeighbourInfo(string name)
262 {
263 foreach (RegionInfo info in m_hyperlinkRegions)
264 {
265 //m_log.Debug(" .. " + info.RegionHandle);
266 if (info.RegionName == name) return info;
267 }
268
269 foreach (RegionInfo info in m_knownRegions.Values)
270 {
271 if (info.RegionName == name)
272 {
273 //m_log.Debug("XXX------ known region " + info.RegionHandle);
274 return info;
275 }
276 }
277
278 return null;
279 }
280
281 public virtual RegionInfo RequestNeighbourInfo(string hostName, uint port)
282 {
283 foreach (RegionInfo info in m_hyperlinkRegions)
284 {
285 //m_log.Debug(" .. " + info.RegionHandle);
286 if ((info.ExternalHostName == hostName) && (info.HttpPort == port))
287 return info;
288 }
289
290 foreach (RegionInfo info in m_knownRegions.Values)
291 {
292 if ((info.ExternalHostName == hostName) && (info.HttpPort == port))
293 {
294 //m_log.Debug("XXX------ known region " + info.RegionHandle);
295 return info;
296 }
297 }
298
299 return null;
300 }
301
261 public virtual RegionInfo RequestClosestRegion(string regionName) 302 public virtual RegionInfo RequestClosestRegion(string regionName)
262 { 303 {
263 foreach (RegionInfo info in m_hyperlinkRegions) 304 foreach (RegionInfo info in m_hyperlinkRegions)
diff --git a/OpenSim/Region/Communications/Local/LocalBackEndServices.cs b/OpenSim/Region/Communications/Local/LocalBackEndServices.cs
index 33bc2fa..c52f825 100644
--- a/OpenSim/Region/Communications/Local/LocalBackEndServices.cs
+++ b/OpenSim/Region/Communications/Local/LocalBackEndServices.cs
@@ -199,6 +199,38 @@ namespace OpenSim.Region.Communications.Local
199 } 199 }
200 200
201 /// <summary> 201 /// <summary>
202 /// Get information about a neighbouring region
203 /// </summary>
204 /// <param name="regionHandle"></param>
205 /// <returns></returns>
206 public RegionInfo RequestNeighbourInfo(string name)
207 {
208 foreach (RegionInfo info in m_regions.Values)
209 {
210 if (info.RegionName == name)
211 return info;
212 }
213
214 return null;
215 }
216
217 /// <summary>
218 /// Get information about a neighbouring region
219 /// </summary>
220 /// <param name="regionHandle"></param>
221 /// <returns></returns>
222 public RegionInfo RequestNeighbourInfo(string host, uint port)
223 {
224 foreach (RegionInfo info in m_regions.Values)
225 {
226 if ((info.ExternalHostName == host) && (info.HttpPort == port))
227 return info;
228 }
229
230 return null;
231 }
232
233 /// <summary>
202 /// Get information about the closet region given a region name. 234 /// Get information about the closet region given a region name.
203 /// </summary> 235 /// </summary>
204 /// <param name="regionName"></param> 236 /// <param name="regionName"></param>
diff --git a/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs b/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs
index a397093..f47abe8 100644
--- a/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs
+++ b/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs
@@ -445,6 +445,28 @@ namespace OpenSim.Region.Communications.OGS1
445 return regionInfo; 445 return regionInfo;
446 } 446 }
447 447
448 /// <summary>
449 /// Get information about a neighbouring region
450 /// </summary>
451 /// <param name="regionHandle"></param>
452 /// <returns></returns>
453 public RegionInfo RequestNeighbourInfo(string name)
454 {
455 // Not implemented yet
456 return null;
457 }
458
459 /// <summary>
460 /// Get information about a neighbouring region
461 /// </summary>
462 /// <param name="regionHandle"></param>
463 /// <returns></returns>
464 public RegionInfo RequestNeighbourInfo(string host, uint port)
465 {
466 // Not implemented yet
467 return null;
468 }
469
448 public RegionInfo RequestClosestRegion(string regionName) 470 public RegionInfo RequestClosestRegion(string regionName)
449 { 471 {
450 foreach (RegionInfo ri in m_remoteRegionInfoCache.Values) 472 foreach (RegionInfo ri in m_remoteRegionInfoCache.Values)