diff options
Updates all IRegionModules to the new style region modules.
Signed-off-by: Melanie <melanie@t-data.com>
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/OptionalModules/Scripting/XmlRpcRouterModule/XmlRpcGridRouterModule.cs | 28 |
1 files changed, 19 insertions, 9 deletions
diff --git a/OpenSim/Region/OptionalModules/Scripting/XmlRpcRouterModule/XmlRpcGridRouterModule.cs b/OpenSim/Region/OptionalModules/Scripting/XmlRpcRouterModule/XmlRpcGridRouterModule.cs index d18ac0a..f2a0e53 100644 --- a/OpenSim/Region/OptionalModules/Scripting/XmlRpcRouterModule/XmlRpcGridRouterModule.cs +++ b/OpenSim/Region/OptionalModules/Scripting/XmlRpcRouterModule/XmlRpcGridRouterModule.cs | |||
@@ -30,6 +30,7 @@ using System.Collections.Generic; | |||
30 | using System.Reflection; | 30 | using System.Reflection; |
31 | 31 | ||
32 | using log4net; | 32 | using log4net; |
33 | using Mono.Addins; | ||
33 | using Nini.Config; | 34 | using Nini.Config; |
34 | using OpenMetaverse; | 35 | using OpenMetaverse; |
35 | 36 | ||
@@ -49,7 +50,8 @@ namespace OpenSim.Region.OptionalModules.Scripting.XmlRpcGridRouterModule | |||
49 | public string uri; | 50 | public string uri; |
50 | } | 51 | } |
51 | 52 | ||
52 | public class XmlRpcGridRouter : IRegionModule, IXmlRpcRouter | 53 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] |
54 | public class XmlRpcGridRouter : INonSharedRegionModule, IXmlRpcRouter | ||
53 | { | 55 | { |
54 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 56 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
55 | 57 | ||
@@ -59,7 +61,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.XmlRpcGridRouterModule | |||
59 | private bool m_Enabled = false; | 61 | private bool m_Enabled = false; |
60 | private string m_ServerURI = String.Empty; | 62 | private string m_ServerURI = String.Empty; |
61 | 63 | ||
62 | public void Initialise(Scene scene, IConfigSource config) | 64 | public void Initialise(IConfigSource config) |
63 | { | 65 | { |
64 | IConfig startupConfig = config.Configs["Startup"]; | 66 | IConfig startupConfig = config.Configs["Startup"]; |
65 | if (startupConfig == null) | 67 | if (startupConfig == null) |
@@ -75,27 +77,35 @@ namespace OpenSim.Region.OptionalModules.Scripting.XmlRpcGridRouterModule | |||
75 | return; | 77 | return; |
76 | } | 78 | } |
77 | 79 | ||
78 | scene.RegisterModuleInterface<IXmlRpcRouter>(this); | ||
79 | m_Enabled = true; | 80 | m_Enabled = true; |
80 | } | 81 | } |
81 | } | 82 | } |
82 | 83 | ||
83 | public void PostInitialise() | 84 | public void AddRegion(Scene scene) |
85 | { | ||
86 | scene.RegisterModuleInterface<IXmlRpcRouter>(this); | ||
87 | } | ||
88 | public void RegionLoaded(Scene scene) | ||
84 | { | 89 | { |
85 | } | 90 | } |
86 | 91 | ||
87 | public void Close() | 92 | public void RemoveRegion(Scene scene) |
88 | { | 93 | { |
94 | scene.UnregisterModuleInterface<IXmlRpcRouter>(this); | ||
89 | } | 95 | } |
90 | 96 | ||
91 | public string Name | 97 | public Type ReplaceableInterface |
92 | { | 98 | { |
93 | get { return "XmlRpcGridRouterModule"; } | 99 | get { return null; } |
94 | } | 100 | } |
95 | 101 | ||
96 | public bool IsSharedModule | 102 | public void Close() |
97 | { | 103 | { |
98 | get { return false; } | 104 | } |
105 | |||
106 | public string Name | ||
107 | { | ||
108 | get { return "XmlRpcGridRouterModule"; } | ||
99 | } | 109 | } |
100 | 110 | ||
101 | public void RegisterNewReceiver(IScriptModule scriptEngine, UUID channel, UUID objectID, UUID itemID, string uri) | 111 | public void RegisterNewReceiver(IScriptModule scriptEngine, UUID channel, UUID objectID, UUID itemID, string uri) |