From 9b66108081a8c8cf79faaa6c541554091c40850e Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Fri, 6 Feb 2009 16:55:34 +0000 Subject: This changeset is the step 1 of 2 in refactoring OpenSim.Region.Environment into a "framework" part and a modules only part. This first changeset refactors OpenSim.Region.Environment.Scenes, OpenSim.Region.Environment.Interfaces, and OpenSim.Region.Interfaces into OpenSim.Region.Framework.{Interfaces,Scenes} leaving only region modules in OpenSim.Region.Environment. The next step will be to move region modules up from OpenSim.Region.Environment.Modules to OpenSim.Region.CoreModules and then sort out which modules are really core modules and which should move out to forge. I've been very careful to NOT BREAK anything. i hope i've succeeded. as this is the work of a whole week i hope i managed to keep track with the applied patches of the last week --- could any of you that did check in stuff have a look at whether it survived? thx! --- .../Shared/Api/Implementation/AsyncCommandManager.cs | 6 +++--- .../Shared/Api/Implementation/LSL_Api.cs | 9 ++++----- .../Shared/Api/Implementation/OSSL_Api.cs | 4 ++-- .../Shared/Api/Implementation/Plugins/HttpRequest.cs | 20 ++++++++++---------- .../Shared/Api/Implementation/Plugins/Listener.cs | 4 ++-- .../Api/Implementation/Plugins/SensorRepeat.cs | 2 +- .../Shared/Api/Implementation/Plugins/XmlRequest.cs | 18 +++++++++--------- 7 files changed, 31 insertions(+), 32 deletions(-) (limited to 'OpenSim/Region/ScriptEngine/Shared/Api/Implementation') diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs index 71a8d0f..cc71bab 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/AsyncCommandManager.cs @@ -31,7 +31,7 @@ using System.Collections.Generic; using System.Threading; using OpenMetaverse; using OpenSim.Framework; -using OpenSim.Region.Environment.Interfaces; +using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.ScriptEngine.Interfaces; using OpenSim.Region.ScriptEngine.Shared; using OpenSim.Region.ScriptEngine.Shared.Api.Plugins; @@ -234,8 +234,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api m_Timer[engine].UnSetTimerEvents(localID, itemID); // Remove from: HttpRequest - IHttpRequests iHttpReq = - engine.World.RequestModuleInterface(); + IHttpRequestModule iHttpReq = + engine.World.RequestModuleInterface(); iHttpReq.StopHttpRequest(localID, itemID); IWorldComm comms = engine.World.RequestModuleInterface(); diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 7564c69..1484638 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -38,12 +38,11 @@ using OpenSim; using OpenSim.Framework; using OpenSim.Framework.Communications.Cache; using OpenSim.Region.Environment; -using OpenSim.Region.Interfaces; -using OpenSim.Region.Environment.Interfaces; +using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Environment.Modules.Avatar.Currency.SampleMoney; using OpenSim.Region.Environment.Modules.World.Land; using OpenSim.Region.Environment.Modules.World.Terrain; -using OpenSim.Region.Environment.Scenes; +using OpenSim.Region.Framework.Scenes; using OpenSim.Region.Physics.Manager; using OpenSim.Region.ScriptEngine.Shared; using OpenSim.Region.ScriptEngine.Shared.Api.Plugins; @@ -8454,8 +8453,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api // in StartHttpRequest m_host.AddScriptLPS(1); - IHttpRequests httpScriptMod = - m_ScriptEngine.World.RequestModuleInterface(); + IHttpRequestModule httpScriptMod = + m_ScriptEngine.World.RequestModuleInterface(); List param = new List(); foreach (object o in parameters.Data) { diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 734b3ef..fa09b0a 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs @@ -35,8 +35,8 @@ using Nini.Config; using OpenSim; using OpenSim.Framework; using OpenSim.Framework.Console; -using OpenSim.Region.Environment.Interfaces; -using OpenSim.Region.Environment.Scenes; +using OpenSim.Region.Framework.Interfaces; +using OpenSim.Region.Framework.Scenes; using OpenSim.Region.ScriptEngine.Shared; using OpenSim.Region.ScriptEngine.Shared.Api.Plugins; using OpenSim.Region.ScriptEngine.Shared.ScriptBase; diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/HttpRequest.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/HttpRequest.cs index f5a965b..4c7dc8d 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/HttpRequest.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/HttpRequest.cs @@ -26,7 +26,7 @@ */ using System; -using OpenSim.Region.Environment.Interfaces; +using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Environment.Modules.Scripting.HttpRequest; using OpenSim.Region.ScriptEngine.Shared; using OpenSim.Region.ScriptEngine.Interfaces; @@ -48,13 +48,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins if (m_CmdManager.m_ScriptEngine.World == null) return; - IHttpRequests iHttpReq = - m_CmdManager.m_ScriptEngine.World.RequestModuleInterface(); + IHttpRequestModule iHttpReq = + m_CmdManager.m_ScriptEngine.World.RequestModuleInterface(); HttpRequestClass httpInfo = null; if (iHttpReq != null) - httpInfo = iHttpReq.GetNextCompletedRequest(); + httpInfo = (HttpRequestClass)iHttpReq.GetNextCompletedRequest(); while (httpInfo != null) { @@ -67,24 +67,24 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins // implemented here yet anyway. Should be fixed if/when maxsize // is supported - iHttpReq.RemoveCompletedRequest(httpInfo.reqID); + iHttpReq.RemoveCompletedRequest(httpInfo.ReqID); object[] resobj = new object[] { - new LSL_Types.LSLString(httpInfo.reqID.ToString()), - new LSL_Types.LSLInteger(httpInfo.status), + new LSL_Types.LSLString(httpInfo.ReqID.ToString()), + new LSL_Types.LSLInteger(httpInfo.Status), new LSL_Types.list(), - new LSL_Types.LSLString(httpInfo.response_body) + new LSL_Types.LSLString(httpInfo.ResponseBody) }; foreach (IScriptEngine e in m_CmdManager.ScriptEngines) { - if (e.PostObjectEvent(httpInfo.localID, + if (e.PostObjectEvent(httpInfo.LocalID, new EventParams("http_response", resobj, new DetectParams[0]))) break; } - httpInfo = iHttpReq.GetNextCompletedRequest(); + httpInfo = (HttpRequestClass)iHttpReq.GetNextCompletedRequest(); } } } diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Listener.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Listener.cs index b72d17c..eba52bf 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Listener.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/Listener.cs @@ -27,7 +27,7 @@ using System; using OpenMetaverse; -using OpenSim.Region.Environment.Interfaces; +using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Environment.Modules.Scripting.WorldComm; using OpenSim.Region.ScriptEngine.Interfaces; using OpenSim.Region.ScriptEngine.Shared; @@ -56,7 +56,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins { while (comms.HasMessages()) { - ListenerInfo lInfo = comms.GetNextMessage(); + ListenerInfo lInfo = (ListenerInfo)comms.GetNextMessage(); //Deliver data to prim's listen handler object[] resobj = new object[] diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/SensorRepeat.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/SensorRepeat.cs index 808d880..f132518 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/SensorRepeat.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/SensorRepeat.cs @@ -30,7 +30,7 @@ using System.Collections.Generic; using OpenMetaverse; using OpenSim.Framework; using OpenSim.Framework.Communications.Cache; -using OpenSim.Region.Environment.Scenes; +using OpenSim.Region.Framework.Scenes; using OpenSim.Region.ScriptEngine.Shared; using OpenSim.Region.ScriptEngine.Shared.Api; diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/XmlRequest.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/XmlRequest.cs index a7699a1..bf1a923 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/XmlRequest.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/Plugins/XmlRequest.cs @@ -26,7 +26,7 @@ */ using System; -using OpenSim.Region.Environment.Interfaces; +using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Environment.Modules.Scripting.XMLRPC; using OpenSim.Region.ScriptEngine.Interfaces; using OpenSim.Region.ScriptEngine.Shared; @@ -52,7 +52,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins if (xmlrpc != null) { - RPCRequestInfo rInfo = xmlrpc.GetNextCompletedRequest(); + RPCRequestInfo rInfo = (RPCRequestInfo)xmlrpc.GetNextCompletedRequest(); while (rInfo != null) { @@ -80,10 +80,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins break; } - rInfo = xmlrpc.GetNextCompletedRequest(); + rInfo = (RPCRequestInfo)xmlrpc.GetNextCompletedRequest(); } - SendRemoteDataRequest srdInfo = xmlrpc.GetNextCompletedSRDRequest(); + SendRemoteDataRequest srdInfo = (SendRemoteDataRequest)xmlrpc.GetNextCompletedSRDRequest(); while (srdInfo != null) { @@ -93,23 +93,23 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins object[] resobj = new object[] { new LSL_Types.LSLInteger(3), - new LSL_Types.LSLString(srdInfo.channel.ToString()), + new LSL_Types.LSLString(srdInfo.Channel.ToString()), new LSL_Types.LSLString(srdInfo.GetReqID().ToString()), new LSL_Types.LSLString(String.Empty), - new LSL_Types.LSLInteger(srdInfo.idata), - new LSL_Types.LSLString(srdInfo.sdata) + new LSL_Types.LSLInteger(srdInfo.Idata), + new LSL_Types.LSLString(srdInfo.Sdata) }; foreach (IScriptEngine e in m_CmdManager.ScriptEngines) { if (e.PostScriptEvent( - srdInfo.m_itemID, new EventParams( + srdInfo.ItemID, new EventParams( "remote_data", resobj, new DetectParams[0]))) break; } - srdInfo = xmlrpc.GetNextCompletedSRDRequest(); + srdInfo = (SendRemoteDataRequest)xmlrpc.GetNextCompletedSRDRequest(); } } } -- cgit v1.1