aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/ApplicationPlugins/ScriptEngine/Components
diff options
context:
space:
mode:
authorTedd Hansen2008-11-08 17:35:48 +0000
committerTedd Hansen2008-11-08 17:35:48 +0000
commit9511a8c76370f21e839114007dcd2b25c69b009a (patch)
treeb63323dfd96ecd1cc3cd560939bd66bb43ec9c1c /OpenSim/ApplicationPlugins/ScriptEngine/Components
parent* Added IClientIM to IClientCore interfaces (diff)
downloadopensim-SC_OLD-9511a8c76370f21e839114007dcd2b25c69b009a.zip
opensim-SC_OLD-9511a8c76370f21e839114007dcd2b25c69b009a.tar.gz
opensim-SC_OLD-9511a8c76370f21e839114007dcd2b25c69b009a.tar.bz2
opensim-SC_OLD-9511a8c76370f21e839114007dcd2b25c69b009a.tar.xz
Work in progress on SECS stuff. Have been holding it off until after 0.6 release. Still messy as hell and doesn't really work yet. Will undergo dramatic changes. AND MOST IMPORTANTLY: Will be conformed to work in coop with todays DNE and XEngine, hopefully one day providing a common interface for all components.
Diffstat (limited to '')
-rw-r--r--OpenSim/ScriptEngine/Components/DotNetEngine/Compilers/Compiler_YP.cs (renamed from OpenSim/ApplicationPlugins/ScriptEngine/Components/ComponentBase.cs)32
-rw-r--r--OpenSim/ScriptEngine/Shared/IScriptCompiler.cs (renamed from OpenSim/ApplicationPlugins/ScriptEngine/Components/EventBase.cs)17
-rw-r--r--OpenSim/ScriptEngine/Shared/IScriptEngineComponent.cs (renamed from OpenSim/ApplicationPlugins/ScriptEngine/Components/CommandBase.cs)13
-rw-r--r--OpenSim/ScriptEngine/Shared/IScriptExecutor.cs (renamed from OpenSim/ApplicationPlugins/ScriptEngine/Components/CompilerBase.cs)16
-rw-r--r--OpenSim/ScriptEngine/Shared/IScriptScheduler.cs (renamed from OpenSim/ApplicationPlugins/ScriptEngine/Components/SchedulerBase.cs)18
5 files changed, 37 insertions, 59 deletions
diff --git a/OpenSim/ApplicationPlugins/ScriptEngine/Components/ComponentBase.cs b/OpenSim/ScriptEngine/Components/DotNetEngine/Compilers/Compiler_YP.cs
index 48c6bfe..c81ad76 100644
--- a/OpenSim/ApplicationPlugins/ScriptEngine/Components/ComponentBase.cs
+++ b/OpenSim/ScriptEngine/Components/DotNetEngine/Compilers/Compiler_YP.cs
@@ -26,28 +26,30 @@
26 */ 26 */
27using System; 27using System;
28using System.Collections.Generic; 28using System.Collections.Generic;
29using System.Reflection;
29using System.Text; 30using System.Text;
31using OpenSim.ScriptEngine.Components.DotNetEngine.Compilers.YP;
32using OpenSim.ScriptEngine.Shared;
30 33
31namespace OpenSim.ApplicationPlugins.ScriptEngine.Components 34namespace OpenSim.ScriptEngine.Components.DotNetEngine.Compilers
32{ 35{
33 /// <summary> 36 public class Compiler_YP: IScriptCompiler
34 /// Generic baseclass for component providers
35 /// </summary>
36 public abstract class ComponentBase //: iProviderBase
37 { 37 {
38 //public abstract iProviderBase CreateInstance(); 38
39 public abstract void Start(); 39 private readonly Compiler_CS m_Compiler_CS = new Compiler_CS();
40 public abstract void Close(); 40
41 public RegionScriptEngineBase scriptEngine; 41 public string Compile(ScriptMetaData scriptMetaData, ref string script)
42 public void Initialize(RegionScriptEngineBase ScriptEngine)
43 { 42 {
44 scriptEngine = ScriptEngine; 43 // Convert script to CS
44 string scriptCS = YP2CS.Convert(ref script);
45 // Use CS compiler to compile it
46 return m_Compiler_CS.Compile(scriptMetaData, ref scriptCS);
45 } 47 }
46 48
47 static ComponentBase() 49 public string PreProcessScript(ref string script)
48 { 50 {
49 // We got loaded -- should we register now? 51 // This is handled by our converter
50 //OpenSim.ApplicationPlugins.ScriptEngine.ComponentProviders.providers.Add(GetType()); 52 return script;
51 } 53 }
52 } 54 }
53} \ No newline at end of file 55}
diff --git a/OpenSim/ApplicationPlugins/ScriptEngine/Components/EventBase.cs b/OpenSim/ScriptEngine/Shared/IScriptCompiler.cs
index 1c0fd52..3bc0c03 100644
--- a/OpenSim/ApplicationPlugins/ScriptEngine/Components/EventBase.cs
+++ b/OpenSim/ScriptEngine/Shared/IScriptCompiler.cs
@@ -26,20 +26,15 @@
26 */ 26 */
27using System; 27using System;
28using System.Collections.Generic; 28using System.Collections.Generic;
29using System.Reflection;
29using System.Text; 30using System.Text;
31using ScriptAssemblies;
30 32
31namespace OpenSim.ApplicationPlugins.ScriptEngine.Components 33namespace OpenSim.ScriptEngine.Shared
32{ 34{
33 public abstract class EventBase : ComponentBase 35 public interface IScriptCompiler : IScriptEngineComponent
34 { 36 {
35 //public override iProviderBase CreateInstance() 37 string Compile(ScriptMetaData scriptMetaData, ref string script);
36 //{ 38 string PreProcessScript(ref string script);
37 // throw new NotImplementedException();
38 //}
39
40 //public override void Start()
41 //{
42 // throw new NotImplementedException();
43 //}
44 } 39 }
45} \ No newline at end of file 40} \ No newline at end of file
diff --git a/OpenSim/ApplicationPlugins/ScriptEngine/Components/CommandBase.cs b/OpenSim/ScriptEngine/Shared/IScriptEngineComponent.cs
index 4708554..3c977a5 100644
--- a/OpenSim/ApplicationPlugins/ScriptEngine/Components/CommandBase.cs
+++ b/OpenSim/ScriptEngine/Shared/IScriptEngineComponent.cs
@@ -28,18 +28,9 @@ using System;
28using System.Collections.Generic; 28using System.Collections.Generic;
29using System.Text; 29using System.Text;
30 30
31namespace OpenSim.ApplicationPlugins.ScriptEngine.Components 31namespace OpenSim.ScriptEngine.Shared
32{ 32{
33 public abstract class CommandBase: ComponentBase 33 public interface IScriptEngineComponent
34 { 34 {
35 //public override iProviderBase CreateInstance()
36 //{
37 // throw new NotImplementedException();
38 //}
39
40 //public override void Start()
41 //{
42 // throw new NotImplementedException();
43 //}
44 } 35 }
45} \ No newline at end of file 36} \ No newline at end of file
diff --git a/OpenSim/ApplicationPlugins/ScriptEngine/Components/CompilerBase.cs b/OpenSim/ScriptEngine/Shared/IScriptExecutor.cs
index e62d1f2..77bea13 100644
--- a/OpenSim/ApplicationPlugins/ScriptEngine/Components/CompilerBase.cs
+++ b/OpenSim/ScriptEngine/Shared/IScriptExecutor.cs
@@ -27,19 +27,13 @@
27using System; 27using System;
28using System.Collections.Generic; 28using System.Collections.Generic;
29using System.Text; 29using System.Text;
30using OpenSim.ScriptEngine.Shared;
30 31
31namespace OpenSim.ApplicationPlugins.ScriptEngine.Components 32namespace OpenSim.ScriptEngine.Shared
32{ 33{
33 public abstract class CompilerBase: ComponentBase 34 public interface IScriptExecutor : IScriptEngineComponent, IScriptEngineRegionComponent
34 { 35 {
35 //public override iProviderBase CreateInstance() 36 void ExecuteCommand(ref ScriptStructure scriptContainer, EventParams p);
36 //{ 37 void ExecuteCommand(EventParams p);
37 // throw new NotImplementedException();
38 //}
39
40 //public override void Start()
41 //{
42 // throw new NotImplementedException();
43 //}
44 } 38 }
45} \ No newline at end of file 39} \ No newline at end of file
diff --git a/OpenSim/ApplicationPlugins/ScriptEngine/Components/SchedulerBase.cs b/OpenSim/ScriptEngine/Shared/IScriptScheduler.cs
index 9d5aff0..3e56c12 100644
--- a/OpenSim/ApplicationPlugins/ScriptEngine/Components/SchedulerBase.cs
+++ b/OpenSim/ScriptEngine/Shared/IScriptScheduler.cs
@@ -27,19 +27,15 @@
27using System; 27using System;
28using System.Collections.Generic; 28using System.Collections.Generic;
29using System.Text; 29using System.Text;
30using OpenMetaverse;
31using OpenSim.ScriptEngine.Shared;
30 32
31namespace OpenSim.ApplicationPlugins.ScriptEngine.Components 33namespace OpenSim.ScriptEngine.Shared
32{ 34{
33 public abstract class SchedulerBase: ComponentBase 35 public interface IScriptScheduler : IScriptEngineComponent
34 { 36 {
35 //public override iProviderBase CreateInstance() 37 void AddScript(ScriptStructure script);
36 //{ 38 void Removecript(uint id, UUID itemID);
37 // throw new NotImplementedException(); 39 void Close();
38 //}
39
40 //public override void Start()
41 //{
42 // throw new NotImplementedException();
43 //}
44 } 40 }
45} \ No newline at end of file 41} \ No newline at end of file