aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs31
1 files changed, 21 insertions, 10 deletions
diff --git a/OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs b/OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs
index 4534024..0f2ba32 100644
--- a/OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs
+++ b/OpenSim/Region/CoreModules/InterGrid/OGSRadmin.cs
@@ -32,7 +32,6 @@ using System.Net;
32using System.Reflection; 32using System.Reflection;
33using System.Text; 33using System.Text;
34using log4net; 34using log4net;
35using Mono.Addins;
36using Nini.Config; 35using Nini.Config;
37using Nwc.XmlRpc; 36using Nwc.XmlRpc;
38using OpenMetaverse; 37using OpenMetaverse;
@@ -43,8 +42,7 @@ using OpenSim.Region.Framework.Scenes;
43 42
44namespace OpenSim.Region.CoreModules.InterGrid 43namespace OpenSim.Region.CoreModules.InterGrid
45{ 44{
46 [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] 45 public class OGSRadmin : IRegionModule
47 public class OGSRadmin : ISharedRegionModule
48 { 46 {
49 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 47 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
50 private readonly List<Scene> m_scenes = new List<Scene>(); 48 private readonly List<Scene> m_scenes = new List<Scene>();
@@ -58,6 +56,7 @@ namespace OpenSim.Region.CoreModules.InterGrid
58 get { return "OGS Supporting RAdmin"; } 56 get { return "OGS Supporting RAdmin"; }
59 } 57 }
60 58
59
61 public void Initialise(IConfigSource source) 60 public void Initialise(IConfigSource source)
62 { 61 {
63 m_settings = source; 62 m_settings = source;
@@ -68,11 +67,6 @@ namespace OpenSim.Region.CoreModules.InterGrid
68 67
69 } 68 }
70 69
71 public Type ReplaceableInterface
72 {
73 get { return null; }
74 }
75
76 public void AddRegion(Scene scene) 70 public void AddRegion(Scene scene)
77 { 71 {
78 lock (m_scenes) 72 lock (m_scenes)
@@ -83,11 +77,15 @@ namespace OpenSim.Region.CoreModules.InterGrid
83 { 77 {
84 lock (m_scenes) 78 lock (m_scenes)
85 m_scenes.Remove(scene); 79 m_scenes.Remove(scene);
86 MainServer.Instance.RemoveXmlRPCHandler("grid_message");
87 } 80 }
88 81
89 public void RegionLoaded(Scene scene) 82 public void RegionLoaded(Scene scene)
90 { 83 {
84
85 }
86
87 public void PostInitialise()
88 {
91 if (m_settings.Configs["Startup"].GetBoolean("gridmode", false)) 89 if (m_settings.Configs["Startup"].GetBoolean("gridmode", false))
92 { 90 {
93 m_com = m_scenes[0].CommsManager; 91 m_com = m_scenes[0].CommsManager;
@@ -95,8 +93,21 @@ namespace OpenSim.Region.CoreModules.InterGrid
95 } 93 }
96 } 94 }
97 95
98 public void PostInitialise() 96 #endregion
97
98 #region IRegionModule
99
100 public void Initialise(Scene scene, IConfigSource source)
101 {
102 m_settings = source;
103
104 lock (m_scenes)
105 m_scenes.Add(scene);
106 }
107
108 public bool IsSharedModule
99 { 109 {
110 get { return true; }
100 } 111 }
101 112
102 #endregion 113 #endregion