aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/OptionalModules/Scripting/Minimodule
diff options
context:
space:
mode:
authorJeff Ames2009-04-21 15:30:03 +0000
committerJeff Ames2009-04-21 15:30:03 +0000
commit13f5dd5f353c5ea5e86944af3dbaa739c8be1a8a (patch)
treedb2753c11ade99bfad52a28c96fc16520df865b1 /OpenSim/Region/OptionalModules/Scripting/Minimodule
parent* Add the ability to update profiles via the cache, so that cached profiles d... (diff)
downloadopensim-SC-13f5dd5f353c5ea5e86944af3dbaa739c8be1a8a.zip
opensim-SC-13f5dd5f353c5ea5e86944af3dbaa739c8be1a8a.tar.gz
opensim-SC-13f5dd5f353c5ea5e86944af3dbaa739c8be1a8a.tar.bz2
opensim-SC-13f5dd5f353c5ea5e86944af3dbaa739c8be1a8a.tar.xz
Update svn properties.
Diffstat (limited to 'OpenSim/Region/OptionalModules/Scripting/Minimodule')
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/ExtensionHandler.cs78
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/IMRMModule.cs12
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IExtension.cs26
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/Minimodule/Object/IObjectShape.cs94
4 files changed, 105 insertions, 105 deletions
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/ExtensionHandler.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/ExtensionHandler.cs
index bc159eb..d3efe9c 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/ExtensionHandler.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/ExtensionHandler.cs
@@ -1,39 +1,39 @@
1using System; 1using System;
2using System.Collections.Generic; 2using System.Collections.Generic;
3using System.Text; 3using System.Text;
4using OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces; 4using OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces;
5 5
6namespace OpenSim.Region.OptionalModules.Scripting.Minimodule 6namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
7{ 7{
8 class ExtensionHandler : IExtension 8 class ExtensionHandler : IExtension
9 { 9 {
10 private readonly Dictionary<Type, object> m_instances; 10 private readonly Dictionary<Type, object> m_instances;
11 11
12 public ExtensionHandler(Dictionary<Type, object> instances) 12 public ExtensionHandler(Dictionary<Type, object> instances)
13 { 13 {
14 m_instances = instances; 14 m_instances = instances;
15 } 15 }
16 16
17 public T Get<T>() 17 public T Get<T>()
18 { 18 {
19 return (T) m_instances[typeof (T)]; 19 return (T) m_instances[typeof (T)];
20 } 20 }
21 21
22 public bool TryGet<T>(out T extension) 22 public bool TryGet<T>(out T extension)
23 { 23 {
24 if (!m_instances.ContainsKey(typeof(T))) 24 if (!m_instances.ContainsKey(typeof(T)))
25 { 25 {
26 extension = default(T); 26 extension = default(T);
27 return false; 27 return false;
28 } 28 }
29 29
30 extension = Get<T>(); 30 extension = Get<T>();
31 return true; 31 return true;
32 } 32 }
33 33
34 public bool Has<T>() 34 public bool Has<T>()
35 { 35 {
36 return m_instances.ContainsKey(typeof (T)); 36 return m_instances.ContainsKey(typeof (T));
37 } 37 }
38 } 38 }
39} 39}
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/IMRMModule.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/IMRMModule.cs
index 4c37a44..05b8bc9 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/IMRMModule.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/IMRMModule.cs
@@ -1,7 +1,7 @@
1namespace OpenSim.Region.OptionalModules.Scripting.Minimodule 1namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
2{ 2{
3 public interface IMRMModule 3 public interface IMRMModule
4 { 4 {
5 void RegisterExtension<T>(T instance); 5 void RegisterExtension<T>(T instance);
6 } 6 }
7} \ No newline at end of file 7} \ No newline at end of file
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IExtension.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IExtension.cs
index b58e600..91c696f 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IExtension.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IExtension.cs
@@ -1,13 +1,13 @@
1using System; 1using System;
2using System.Collections.Generic; 2using System.Collections.Generic;
3using System.Text; 3using System.Text;
4 4
5namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces 5namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Interfaces
6{ 6{
7 public interface IExtension 7 public interface IExtension
8 { 8 {
9 T Get<T>(); 9 T Get<T>();
10 bool TryGet<T>(out T extension); 10 bool TryGet<T>(out T extension);
11 bool Has<T>(); 11 bool Has<T>();
12 } 12 }
13} 13}
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Object/IObjectShape.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Object/IObjectShape.cs
index ed24680..0018b2a 100644
--- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Object/IObjectShape.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Object/IObjectShape.cs
@@ -1,48 +1,48 @@
1using System; 1using System;
2using System.Collections.Generic; 2using System.Collections.Generic;
3using System.Text; 3using System.Text;
4using OpenMetaverse; 4using OpenMetaverse;
5 5
6namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Object 6namespace OpenSim.Region.OptionalModules.Scripting.Minimodule.Object
7{ 7{
8 public enum SculptType 8 public enum SculptType
9 { 9 {
10 Default = 1, 10 Default = 1,
11 Sphere = 1, 11 Sphere = 1,
12 Torus = 2, 12 Torus = 2,
13 Plane = 3, 13 Plane = 3,
14 Cylinder = 4 14 Cylinder = 4
15 } 15 }
16 16
17 public enum HoleShape 17 public enum HoleShape
18 { 18 {
19 Default = 0x00, 19 Default = 0x00,
20 Circle = 0x10, 20 Circle = 0x10,
21 Square = 0x20, 21 Square = 0x20,
22 Triangle = 0x30 22 Triangle = 0x30
23 } 23 }
24 24
25 public enum PrimType 25 public enum PrimType
26 { 26 {
27 NotPrimitive = 255, 27 NotPrimitive = 255,
28 Box = 0, 28 Box = 0,
29 Cylinder = 1, 29 Cylinder = 1,
30 Prism = 2, 30 Prism = 2,
31 Sphere = 3, 31 Sphere = 3,
32 Torus = 4, 32 Torus = 4,
33 Tube = 5, 33 Tube = 5,
34 Ring = 6, 34 Ring = 6,
35 Sculpt = 7 35 Sculpt = 7
36 } 36 }
37 37
38 public interface IObjectShape 38 public interface IObjectShape
39 { 39 {
40 UUID SculptMap { get; set; } 40 UUID SculptMap { get; set; }
41 SculptType SculptType { get; set; } 41 SculptType SculptType { get; set; }
42 42
43 HoleShape HoleType { get; set; } 43 HoleShape HoleType { get; set; }
44 Double HoleSize { get; set; } 44 Double HoleSize { get; set; }
45 PrimType PrimType { get; set; } 45 PrimType PrimType { get; set; }
46 46
47 } 47 }
48} \ No newline at end of file 48} \ No newline at end of file